MCPcopy Create free account
hub / github.com/aws-cloudformation/rain / Map

Function Map

cft/parse/parse.go:49–57  ·  view source on GitHub ↗

Map returns a cft.Template parsed from a map[string]interface{}

(input map[string]interface{})

Source from the content-addressed store, hash-verified

47
48// Map returns a cft.Template parsed from a map[string]interface{}
49func Map(input map[string]interface{}) (*cft.Template, error) {
50 var node yaml.Node
51 err := node.Encode(input)
52 if err != nil {
53 return &cft.Template{}, err
54 }
55
56 return Node(&node)
57}
58
59// String returns a cft.Template parsed from a string
60func String(input string) (*cft.Template, error) {

Callers 9

parse_test.goFile · 0.92
TestVerifyOutputFunction · 0.92
TestEmptySubFunction · 0.92
TestMatchPathFunction · 0.92
TestMergeTemplatesClashFunction · 0.92
mergeTemplatesFunction · 0.92

Calls 1

NodeFunction · 0.70

Tested by 7

TestVerifyOutputFunction · 0.74
TestEmptySubFunction · 0.74
TestMatchPathFunction · 0.74
TestMergeTemplatesClashFunction · 0.74