convertintschema

package
v1.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromResourceData

func FromResourceData(
	objSchema map[string]*schema.Schema, d ResourceGetter, outObj any,
) error

FromResourceData unloads d into outObj, where outObj is a generated intschema struct and objSchema is its Terraform schema.

func ToResourceData

func ToResourceData(obj any, d *schema.ResourceData) diag.Diagnostics

ToResourceData unloads obj into d, where obj is a generated intschema struct.

Types

type ResourceGetter

type ResourceGetter interface {
	Get(key string) any
	Id() string
}

ResourceGetter is a subset of the read-only interface to read resource data from schema.ResourceData and schema.ResourceDiff.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL