// Code generated by generators/singular-data-source/main.go; DO NOT EDIT. package appstream import ( "context" "github.com/hashicorp/terraform-plugin-framework/tfsdk" "github.com/hashicorp/terraform-plugin-framework/types" . "github.com/hashicorp/terraform-provider-awscc/internal/generic" "github.com/hashicorp/terraform-provider-awscc/internal/registry" ) func init() { registry.AddDataSourceTypeFactory("awscc_appstream_entitlement", entitlementDataSourceType) } // entitlementDataSourceType returns the Terraform awscc_appstream_entitlement data source type. // This Terraform data source type corresponds to the CloudFormation AWS::AppStream::Entitlement resource type. func entitlementDataSourceType(ctx context.Context) (tfsdk.DataSourceType, error) { attributes := map[string]tfsdk.Attribute{ "app_visibility": { // Property: AppVisibility // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, "attributes": { // Property: Attributes // CloudFormation resource type schema: // { // "insertionOrder": false, // "items": { // "additionalProperties": false, // "properties": { // "Name": { // "type": "string" // }, // "Value": { // "type": "string" // } // }, // "required": [ // "Name", // "Value" // ], // "type": "object" // }, // "type": "array", // "uniqueItems": true // } Attributes: tfsdk.SetNestedAttributes( map[string]tfsdk.Attribute{ "name": { // Property: Name Type: types.StringType, Computed: true, }, "value": { // Property: Value Type: types.StringType, Computed: true, }, }, tfsdk.SetNestedAttributesOptions{}, ), Computed: true, }, "created_time": { // Property: CreatedTime // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, "description": { // Property: Description // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, "last_modified_time": { // Property: LastModifiedTime // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, "name": { // Property: Name // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, "stack_name": { // Property: StackName // CloudFormation resource type schema: // { // "type": "string" // } Type: types.StringType, Computed: true, }, } attributes["id"] = tfsdk.Attribute{ Description: "Uniquely identifies the resource.", Type: types.StringType, Required: true, } schema := tfsdk.Schema{ Description: "Data Source schema for AWS::AppStream::Entitlement", Version: 1, Attributes: attributes, } var opts DataSourceTypeOptions opts = opts.WithCloudFormationTypeName("AWS::AppStream::Entitlement").WithTerraformTypeName("awscc_appstream_entitlement") opts = opts.WithTerraformSchema(schema) opts = opts.WithAttributeNameMap(map[string]string{ "app_visibility": "AppVisibility", "attributes": "Attributes", "created_time": "CreatedTime", "description": "Description", "last_modified_time": "LastModifiedTime", "name": "Name", "stack_name": "StackName", "value": "Value", }) singularDataSourceType, err := NewSingularDataSourceType(ctx, opts...) if err != nil { return nil, err } return singularDataSourceType, nil }