utils

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2024 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

View Source
const (
	MongoPrimaryName     = "_id"
	QueryOperationPrefix = "$"
)

Variables

This section is empty.

Functions

func AssertEqual

func AssertEqual(src, dst interface{}) bool

func CheckTruth

func CheckTruth(vals ...string) bool

CheckTruth check string true or not

func Contains

func Contains(elems []string, elem string) bool

func FileWithLineNum

func FileWithLineNum() string

FileWithLineNum return the file name and line number of the current file

func IsValidDBNameChar

func IsValidDBNameChar(c rune) bool

func ToArray

func ToArray(v interface{}) (r []interface{})

func ToBson

func ToBson(i interface{}) (bson.M, error)

func ToString

func ToString(value interface{}) string

func ToStringKey

func ToStringKey(values ...interface{}) string

func ValueOf

func ValueOf(i interface{}) reflect.Value

Types

This section is empty.

Jump to

Keyboard shortcuts

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