iter

package
v2.1.2 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsMap

func AsMap(ctx context.Context, src mapiter.Source) (map[string]interface{}, error)

func WalkMap

func WalkMap(ctx context.Context, src mapiter.Source, visitor MapVisitor) error

Types

type MapVisitor

type MapVisitor interface {
	Visit(string, interface{}) error
}

MapVisitor is a specialized visitor for our purposes. Whereas mapiter.Visitor supports any type of key, this visitor assumes the key is a string

type MapVisitorFunc

type MapVisitorFunc func(string, interface{}) error

func (MapVisitorFunc) Visit

func (fn MapVisitorFunc) Visit(s string, v interface{}) error

Jump to

Keyboard shortcuts

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