Documentation
¶
Index ¶
- Variables
- func Abs[T constraints.Integer | constraints.Float](x T) T
- func GetHostname() (string, error)
- func IP() (string, error)
- func IsInDocker() bool
- func IsInK8s() bool
- func Paginate[T int | int32 | int64](totalCount, page, pageSize T) (start, end T, totalPage T, err error)
- func ParseAddr(addr string) (host string, port int, err error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrParameterInvalid = errors.New("parameter invalid") ErrPageOutOfRange = errors.New("page out of range") ErrIndexOutOfRange = errors.New("index out of range") ErrRedisOptIsRequired = errors.New("redis options is required") ErrDuplicateExcelFieldName = errors.New("duplicate excel field name") )
Functions ¶
func Abs ¶
func Abs[T constraints.Integer | constraints.Float](x T) T
func GetHostname ¶
func IsInDocker ¶
func IsInDocker() bool
IsInDocker 检测是否在Docker中运行 IsInDocker checks if the application is running in Docker
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.