util

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2022 License: Apache-2.0 Imports: 3 Imported by: 81

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoolPtr

func BoolPtr(v bool) *bool

func CastToInterfaceArr

func CastToInterfaceArr(arr []string) []interface{}

func CastToStringArr

func CastToStringArr(arr []interface{}) []string

func FormatCommaSeparatedString

func FormatCommaSeparatedString(thing interface{}) string

func MergeSchema

func MergeSchema(schemata ...map[string]*schema.Schema) map[string]*schema.Schema

Types

type HclPredicate

type HclPredicate func(hcl string) bool

func SchemaHasKey

func SchemaHasKey(skeema map[string]*schema.Schema) HclPredicate

type Lens

type Lens func(key string, value interface{}) []error

func MkLens

func MkLens(d *schema.ResourceData) Lens

type ResourceData

type ResourceData struct{ *schema.ResourceData }

func (*ResourceData) GetBool

func (d *ResourceData) GetBool(key string, onlyIfChanged bool) bool

func (*ResourceData) GetBoolRef

func (d *ResourceData) GetBoolRef(key string, onlyIfChanged bool) *bool

func (*ResourceData) GetInt

func (d *ResourceData) GetInt(key string, onlyIfChanged bool) int

func (*ResourceData) GetList

func (d *ResourceData) GetList(key string) []string

func (*ResourceData) GetSet

func (d *ResourceData) GetSet(key string) []string

func (*ResourceData) GetString

func (d *ResourceData) GetString(key string, onlyIfChanged bool) string

type Schema

type Schema map[string]*schema.Schema

Jump to

Keyboard shortcuts

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