Documentation

Overview

Package queryparams provides conversion from versioned runtime objects to URL query values

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Convert

func Convert(obj interface{}) (url.Values, error)

Convert takes an object and converts it to a url.Values object using JSON tags as parameter names. Only top-level simple values, arrays, and slices are serialized. Embedded structs, maps, etc. will not be serialized.

Types

type Marshaler

type Marshaler interface {
	MarshalQueryParameter() (string, error)
}

Marshaler converts an object to a query parameter string representation

type Unmarshaler

type Unmarshaler interface {
	UnmarshalQueryParameter(string) error
}

Unmarshaler converts a string representation to an object

Source Files