asynq_auxiliary

package
v0.9.4 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientOption

type ClientOption func(*ClientSettings)

ClientOption 客户端选项

func WithClientJsonMarshalBinary added in v0.4.1

func WithClientJsonMarshalBinary() ClientOption

WithClientJsonMarshalBinary 使用 json.Marshal

func WithClientMarshalBinary

func WithClientMarshalBinary(f func(any) ([]byte, error)) ClientOption

WithClientMarshalBinary 使用指定序列化

type ClientSettings

type ClientSettings struct {
	MarshalBinary func(any) ([]byte, error)
}

ClientSettings 客户端配置

func NewClientSettings

func NewClientSettings() *ClientSettings

NewClientSettings 新建配置, 默认使用 proto.Marshal

type HandlerOption

type HandlerOption func(*HandlerSettings)

HandlerOption 处理器选项

func WithHandlerJsonUnmarshalBinary added in v0.4.1

func WithHandlerJsonUnmarshalBinary() HandlerOption

WithHandlerUnmarshalBinary 使用 json.Unmarshal

func WithHandlerUnmarshalBinary

func WithHandlerUnmarshalBinary(f func([]byte, any) error) HandlerOption

WithHandlerUnmarshalBinary 指定反序列化

type HandlerSettings

type HandlerSettings struct {
	// UnmarshalBinary parses the binary data and stores the result
	// in the value pointed to by v.
	UnmarshalBinary func([]byte, any) error
}

HandlerSettings 处理器配置

func NewHandlerSettings

func NewHandlerSettings() *HandlerSettings

NewHandlerSettings 新建处理器选项, 默认使用 proto.Unmarshal

Jump to

Keyboard shortcuts

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