extract

package
v0.5.21 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package extract contains functions for extracting JSON results into given structure or slice pointers. Those are wrappers over `json.Marshall` and `json.Unmarshall` functions with additional validation built it

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Into

func Into(body interface{}, to interface{}) error

func IntoSlicePtr

func IntoSlicePtr(body, to interface{}, label string) error

IntoSlicePtr will unmarshal the provided body into the provided interface{} (to).

func IntoStructPtr

func IntoStructPtr(body, to interface{}, label string) error

IntoStructPtr will unmarshal the given body into the provided interface{} (to).

func JsonMarshal

func JsonMarshal(t interface{}) ([]byte, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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