yaml

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

README

yaml

yaml provides functions for working with yaml data

Functions

dumps(obj) string

serialize obj to a yaml string

parameters:

name type description
obj object input object
loads(source) object

read a source yaml string to a starlark object

parameters:

name type description
source string input string of yaml data

Documentation

Overview

Package yaml implements a yaml parser for the starlark programming dialect

outline: yaml
  yaml provides functions for working with yaml data
  path: encoding/yaml
  functions:
    dumps(obj) string
      serialize obj to a yaml string
      params:
        obj object
          input object
    loads(source) object
      read a source yaml string to a starlark object
      params:
        source string
          input string of yaml data

Index

Constants

View Source
const ModuleName = "encoding/yaml.star"

ModuleName defines the expected name for this Module when used in starlark's load() function, eg: load('encoding/yaml.star', 'yaml')

Variables

This section is empty.

Functions

func Dumps

func Dumps(thread *starlark.Thread, _ *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (starlark.Value, error)

Dumps serializes a starlark object to a yaml string

func LoadModule

func LoadModule() (starlark.StringDict, error)

LoadModule loads the base64 module. It is concurrency-safe and idempotent.

func Loads

func Loads(thread *starlark.Thread, _ *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (starlark.Value, error)

Loads gets all values from a yaml source

Types

This section is empty.

Jump to

Keyboard shortcuts

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