tool

package
v0.0.0-...-e7df039 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2022 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Trace   *log.Logger
	Info    *log.Logger
	Warning *log.Logger
	Error   *log.Logger
)

Functions

This section is empty.

Types

type File

type File struct{}

func NewFile

func NewFile() *File

func (*File) Create

func (f *File) Create(pathname string) (*os.File, error)

func (*File) IsExists

func (f *File) IsExists(pathname string) (bool, error)

func (*File) Mkdir

func (f *File) Mkdir(dir string) error

func (*File) MkdirAll

func (f *File) MkdirAll(dir string) error

func (*File) Open

func (f *File) Open(pathname string) (*os.File, error)

func (*File) OpenFile

func (f *File) OpenFile(name string, perm os.FileMode) (*os.File, error)

type Logs

type Logs struct {
	// contains filtered or unexported fields
}

func NewLogs

func NewLogs() *Logs

func (*Logs) Initialized

func (l *Logs) Initialized(name string) error

type M

type M struct {
}

func New

func New() *M

func (*M) Base64ToDecode

func (_ *M) Base64ToDecode(d string) (string, error)

func (*M) Base64ToEncode

func (_ *M) Base64ToEncode(d []byte) string

func (*M) ContainSliceIndex

func (_ *M) ContainSliceIndex(src interface{}, k int) int8

func (*M) Contains

func (_ *M) Contains(k interface{}, d ...interface{}) int8

func (*M) HumpToU

func (m *M) HumpToU(d string) string

func (*M) MatchPattern

func (m *M) MatchPattern(v, pattern string, s ...int) int8

func (*M) RandomStr

func (_ *M) RandomStr(size int) string

func (*M) SourceFilter

func (_ *M) SourceFilter(d ...*string)

func (*M) SourceFuncTP

func (_ *M) SourceFuncTP(d interface{}) string

func (*M) SourceGrab

func (_ *M) SourceGrab(d string, start, length int) string

func (*M) ToJson

func (_ *M) ToJson(d interface{}) (string, error)

func (*M) ToStruct

func (_ *M) ToStruct(d, res interface{}) error

func (*M) UToHump

func (_ *M) UToHump(d string) string

Jump to

Keyboard shortcuts

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