convert

package
v0.0.0-...-dcbaf51 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: MulanPSL-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package convert 类型转换包

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToStr

func ToStr(value interface{}) string

ToStr 将interface转为string

Types

type StrTo

type StrTo string

func (StrTo) Int

func (s StrTo) Int() (int, error)

Int string转int

func (StrTo) Int64

func (s StrTo) Int64() (int64, error)

Int64 string转为int64

func (StrTo) MustInt

func (s StrTo) MustInt() int

MustInt string强制转为int

func (StrTo) MustInt64

func (s StrTo) MustInt64() int64

MustInt64 string强制转为int64

func (StrTo) MustUInt32

func (s StrTo) MustUInt32() uint32

MustUInt32 string强制转为uint32

func (StrTo) MustUInt64

func (s StrTo) MustUInt64() uint64

MustUInt64 string强制转为uint64

func (StrTo) MustUint

func (s StrTo) MustUint() uint

MustUint string强制转为uint

func (StrTo) String

func (s StrTo) String() string

String string转string

func (StrTo) UInt32

func (s StrTo) UInt32() (uint32, error)

UInt32 string转为uint32

func (StrTo) UInt64

func (s StrTo) UInt64() (uint64, error)

UInt64 string转为uint64

func (StrTo) Uint

func (s StrTo) Uint() (uint, error)

Uint string转为uint

Jump to

Keyboard shortcuts

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