populate

package
v3.2.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2016 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Overview

Package populate provides function to populate Go values from an untyped interface{} soup.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Lax

func Lax(dst, src interface{}) error

Lax populates dst from src. Src may contain elements which cannot be mapped to dst in which case they are ignored silently.

func Strict

func Strict(dst, src interface{}) error

Strict populates dst from src failing if elements in src cannot be mapped to dst.

Types

type Populator

type Populator interface {
	Populate(src interface{}) error
}

Jump to

Keyboard shortcuts

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