parameter

package
v0.0.0-...-fb1cdef Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Body

func Body(pointer interface{}, opts ...request.Option) request.HandlerParams

Body - takes pointer to structure and saves casted request body into context and pointer.

Result can be retrieved from context using 'context.QueryParams.Body'.

func Bool

func Bool(key string, place placing.Placing, opts ...request.Option) request.HandlerParams

Bool - mandatory boolean Parameter from request by 'key'.

Result can be retrieved from context using 'context.QueryParams.Bool'.

func CustomBody

func CustomBody(unmarshal types.Unmarshaler, pointer interface{}, opts ...request.Option) request.HandlerParams

CustomBody - takes unmarshaler and pointer to structure and saves casted request body into context.

Result can be retrieved from context using 'context.QueryParams.Body'.

func Description

func Description(desc string) request.HandlerParams

func Float

func Float(key string, place placing.Placing, opts ...request.Option) request.HandlerParams

Float - mandatory floating point number Parameter from request by 'key'.

Result can be retrieved from context using 'context.QueryParams.Float'.

func Header(key string) request.HandlerParams

func Integer

func Integer(key string, place placing.Placing, opts ...request.Option) request.HandlerParams

Integer - queries mandatory integer Parameter from request by 'key'.

Result can be retrieved from context using 'context.QueryParams.Integer'.

func String

func String(key string, place placing.Placing, opts ...request.Option) request.HandlerParams

String - mandatory string Parameter from request by 'key'.

Result can be retrieved from context using 'context.QueryParams.String'.

func Time

func Time(key, layout string, place placing.Placing, opts ...request.Option) request.HandlerParams

Time - mandatory time Parameter from request by 'key' using 'layout'.

Result can be retrieved from context using 'context.QueryParams.Time'.

Types

This section is empty.

Jump to

Keyboard shortcuts

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