schema

package
v0.0.0-...-4add889 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attribute

type Attribute struct {
	Name string `json:"-"`
	Type
}

type PrimitiveType

type PrimitiveType string
const (
	String    PrimitiveType = "String"
	Long      PrimitiveType = "Long"
	Integer   PrimitiveType = "Integer"
	Double    PrimitiveType = "Double"
	Boolean   PrimitiveType = "Boolean"
	Timestamp PrimitiveType = "Timestamp"
)

type Property

type Property struct {
	Name              string     `json:"-"`
	Documentation     string     `json:"Documentation"`
	DuplicatesAllowed bool       `json:"DuplicatesAllowed"`
	Required          bool       `json:"Required"`
	UpdateType        UpdateType `json:"UpdateType"`
	Type
}

type PropertyType

type PropertyType struct {
	Name          string               `json:"-"`
	ResourceType  *ResourceType        `json:"-"`
	Documentation string               `json:"Documentation"`
	Properties    map[string]*Property `json:"Properties"`
}

func (*PropertyType) CtyType

func (pt *PropertyType) CtyType() cty.Type

type ResourceType

type ResourceType struct {
	Name          string                `json:"-"`
	Documentation string                `json:"Documentation"`
	Attributes    map[string]*Attribute `json:"Attributes"`
	Properties    map[string]*Property  `json:"Properties"`
}

type Schema

type Schema struct {
	ResourceTypes       map[string]*ResourceType `json:"ResourceTypes"`
	ResourceSpecVersion string                   `json:"ResourceSpecificationVersion"`
	PropertyTypes       map[string]*PropertyType `json:"PropertyTypes"`
}

func Builtin

func Builtin() *Schema

func Load

func Load(r io.Reader) (*Schema, error)

type Type

type Type struct {
	TypeName          string        `json:"Type"`
	PropertyType      *PropertyType `json:"-"`
	PrimitiveType     PrimitiveType `json:"PrimitiveType"`
	ItemTypeName      string        `json:"ItemType"`
	ItemPropertyType  *PropertyType `json:"-"`
	ItemPrimitiveType PrimitiveType `json:"ItemPrimitiveType"`
}

func (*Type) CtyType

func (t *Type) CtyType() cty.Type

type UpdateType

type UpdateType string
const (
	Mutable     UpdateType = "Mutable"
	Immutable   UpdateType = "Immutable"
	Conditional UpdateType = "Conditional"
)

Jump to

Keyboard shortcuts

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