utils

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2020 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

View Source
const Addr addr = iota
View Source
const Array arr = iota
View Source
const Captcha captcha = iota
View Source
const Cmd cm = iota
View Source
const Conv conv = iota
View Source
const Crypto crypto = iota
View Source
const Dir di = iota
View Source
const FULL = "2006-01-02 15:04:05"
View Source
const File fi = iota
View Source
const Goroutine goroutine = iota
View Source
const HMS = "15:04:05"
View Source
const HttpClient hc = iota
View Source
const Json json = iota
View Source
const Net ne = iota
View Source
const Process pro = iota
View Source
const Rand rd = iota
View Source
const Signal sig = iota
View Source
const String str = iota
View Source
const Structure structure = iota
View Source
const System system = iota
View Source
const Ternary ternary = iota
View Source
const Time ti = iota
View Source
const YMD = "2006-01-02"
View Source
const Zip zip = iota

Variables

This section is empty.

Functions

func Struct

func Struct(dst interface{}) *destination

Types

type Date

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

func (Date) Day

func (d Date) Day() T

func (Date) Format

func (d Date) Format(format string) string

func (Date) Hour

func (d Date) Hour() T

func (Date) Minute

func (d Date) Minute() T

func (Date) Month

func (d Date) Month() T

func (Date) Second

func (d Date) Second() T

func (Date) Time

func (d Date) Time() time.Time

func (Date) Year

func (d Date) Year() T

type Image

type Image struct {
	*image.Paletted
	// contains filtered or unexported fields
}

Image struct

func (*Image) Digits

func (m *Image) Digits() string

func (*Image) ToBase64

func (m *Image) ToBase64() []byte

func (*Image) ToPNG

func (m *Image) ToPNG() []byte

ToPNG encodes an image to PNG and returns the res as a byte slice.

func (*Image) Write

func (m *Image) Write(w io.Writer) (int64, error)

Write writes captcha image in PNG format into the given writer.

type Info

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

func (Info) Append

func (i Info) Append(bts []byte) Info

func (Info) Bytes

func (i Info) Bytes() []byte

func (Info) LastError

func (i Info) LastError() error

func (Info) Slice

func (i Info) Slice(start int, end int) Info

func (Info) String

func (i Info) String() string

func (Info) WriteToBytes

func (i Info) WriteToBytes(bts []byte) error

func (Info) WriteToPath

func (i Info) WriteToPath(path string) error

func (Info) WriteToReader

func (i Info) WriteToReader(w io.Writer) error

type Request

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

func (*Request) Bytes

func (r *Request) Bytes() []byte

func (*Request) Code

func (r *Request) Code() int

func (*Request) LastError

func (r *Request) LastError() error

func (*Request) RequestHeader

func (r *Request) RequestHeader() http.Header

func (*Request) ResponseHeader

func (r *Request) ResponseHeader() http.Header

func (*Request) String

func (r *Request) String() string

type T

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

func (T) Begin

func (t T) Begin() int64

func (T) End

func (t T) End() int64

func (T) Get

func (t T) Get() int

type Ticker

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

func (*Ticker) Start

func (ticker *Ticker) Start()

func (*Ticker) Stop

func (ticker *Ticker) Stop()

Jump to

Keyboard shortcuts

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