MCPcopy
hub / github.com/carvel-dev/ytt / AssignType

Method AssignType

pkg/workspace/datavalues/schema.go:94–96  ·  view source on GitHub ↗

AssignType decorates `doc` with type metadata sourced from this Schema. If `doc` does not conform to the AST structure of this Schema, the returned TypeCheck contains the violations. No other type check is performed.

(doc *yamlmeta.Document)

Source from the content-addressed store, hash-verified

92// If `doc` does not conform to the AST structure of this Schema, the returned TypeCheck contains the violations.
93// No other type check is performed.
94func (s *Schema) AssignType(doc *yamlmeta.Document) schema.TypeCheck {
95 return s.DocType.AssignTypeTo(doc)
96}
97
98// DefaultDataValues returns a copy of the default values declared in this Schema.
99func (s *Schema) DefaultDataValues() *yamlmeta.Document {

Callers 1

typeAndCheckMethod · 0.80

Calls 1

AssignTypeToMethod · 0.65

Tested by

no test coverage detected