stdutil

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustString

func MustString(v interface{}) string

MustString convert value(basic type) to string, will panic on convert a complex type.

func PanicIf

func PanicIf(err error)

PanicIf if error is not empty

func PanicIfErr

func PanicIfErr(err error)

PanicIfErr if error is not empty

func Panicf

func Panicf(format string, v ...interface{})

Panicf format panic message use fmt.Sprintf

func ToString

func ToString(v interface{}) string

ToString always convert value to string

func TryString

func TryString(v interface{}) (string, error)

TryString try to convert a value to string

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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