hcl

package
v1.1.11 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(out interface{}, in string) error

Decode reads the given input and decodes it into the structure given by `out`.

func DecodeObject

func DecodeObject(out interface{}, n ast.Node) error

DecodeObject is a lower-level version of Decode. It decodes a raw Object into the given output.

func Parse

func Parse(input string) (*ast.File, error)

Parse parses the given input and returns the root object.

The input format can be either HCL or JSON.

func ParseBytes

func ParseBytes(in []byte) (*ast.File, error)

ParseBytes accepts as input byte slice and returns ast tree.

Input can be either JSON or HCL

func ParseString

func ParseString(input string) (*ast.File, error)

ParseString accepts input as a string and returns ast tree.

func Unmarshal

func Unmarshal(bs []byte, v interface{}) error

Unmarshal accepts a byte slice as input and writes the data to the value pointed to by v.

Types

This section is empty.

Directories

Path Synopsis
hcl
ast
printer
Package printer implements printing of AST nodes to HCL format.
Package printer implements printing of AST nodes to HCL format.
json

Jump to

Keyboard shortcuts

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