gen

package
v0.95.0 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	PreambleTemplate, _ = template.New("preambleTemplate").Parse(preambleTemplateContent)

	DefinitionTemplate, _ = template.New("definitionTemplate").Parse(definitionTemplateContent)

	AssertionsTemplate, _ = template.New("assertionsTemplate").Funcs(genhelpers.BuildTemplateFuncMap(
		genhelpers.FirstLetterLowercase,
		genhelpers.FirstLetter,
		genhelpers.SnakeCaseToCamel,
	)).Parse(assertionsTemplateContent)

	AllTemplates = []*template.Template{PreambleTemplate, DefinitionTemplate, AssertionsTemplate}
)

Functions

func GetResourceSchemaDetails

func GetResourceSchemaDetails() []genhelpers.ResourceSchemaDetails

Types

type PreambleModel

type PreambleModel struct {
	PackageName               string
	AdditionalStandardImports []string
}

TODO [SNOW-1501905]: extract to commons?

type ResourceAssertionsModel

type ResourceAssertionsModel struct {
	Name       string
	Attributes []ResourceAttributeAssertionModel
	PreambleModel
}

func ModelFromResourceSchemaDetails

func ModelFromResourceSchemaDetails(resourceSchemaDetails genhelpers.ResourceSchemaDetails) ResourceAssertionsModel

func (ResourceAssertionsModel) SomeFunc

func (m ResourceAssertionsModel) SomeFunc()

type ResourceAttributeAssertionModel

type ResourceAttributeAssertionModel struct {
	Name          string
	AttributeType string
}

type ResourceSchemaDef

type ResourceSchemaDef struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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