Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockContent ¶
type BlockContent struct {
*hcl.Block
// Range represents range of the block in HCL syntax
// or closest available representative range in JSON
Range hcl.Range
}
blockContent represents HCL or JSON block content
type BodyContent ¶
type BodyContent struct {
Attributes hcl.Attributes
Blocks []*BlockContent
RangePtr *hcl.Range
}
bodyContent represents an HCL or JSON body content
func DecodeBody ¶
func DecodeBody(body hcl.Body, bodySchema *schema.BodySchema) BodyContent
DecodeBody produces content of either HCL or JSON body JSON body requires schema for decoding, empty bodyContent is returned if nil schema is provided
Click to show internal directories.
Click to hide internal directories.