util

package
v0.0.0-...-4a3359c Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2021 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAllInsertColumns

func GetAllInsertColumns(v interface{}) []string

func GetAllInsertValues

func GetAllInsertValues(v interface{}) []interface{}

func GetErrorMsg

func GetErrorMsg(err error) string

func GetInsertValues

func GetInsertValues(v interface{}, fields []string) []interface{}

func GetPublicKey

func GetPublicKey(keyPath string) *rsa.PublicKey

func NewTLSConfig

func NewTLSConfig(tlsConfig *meta.TLSCertificate) *tls.Config

func RetrieveAuthToken

func RetrieveAuthToken(ctx context.Context) (string, bool)

func RetrieveUserID

func RetrieveUserID(ctx context.Context) (string, bool)

func SetAuthParamsFromMetaData

func SetAuthParamsFromMetaData(ctx context.Context, params **meta.RequestParams) (ok bool)

func ToBsonDoc

func ToBsonDoc(v interface{}) (d bson.D, err error)

func ToBsonMap

func ToBsonMap(v interface{}) (d bson.M, err error)

func ToMap

func ToMap(v interface{}) map[string]interface{}

func ToQueryMap

func ToQueryMap(v url.Values) (qm map[string]interface{})

Types

This section is empty.

Jump to

Keyboard shortcuts

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