msg

package
v3.1.6 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2026 License: GPL-3.0 Imports: 1 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Request

type Request struct {
	ReqType  RequestType
	ID       uint64
	Msg      sdk.Msg
	Retry    uint64
	MaxRetry uint64
}

Request is the struct for sending a request to the sender worker.

func NewRequest

func NewRequest(reqType RequestType, id uint64, msg sdk.Msg, maxRetry uint64) Request

NewRequest creates a new request object.

func (Request) IncreaseRetry

func (req Request) IncreaseRetry() Request

IncreaseRetry increases the retry count of the request and returns a new request.

type RequestType

type RequestType int

RequestType represents the type of the request.

const (
	RequestTypeCreateGroupRound1 RequestType = iota
	RequestTypeCreateGroupRound2
	RequestTypeCreateGroupConfirm
	RequestTypeCreateGroupComplain
	RequestTypeUpdateDE
	RequestTypeSubmitSignature
)

type Response

type Response struct {
	Request Request
	Success bool
	TxHash  string
	Err     error
}

Response is the struct for identifying the result of the request.

func NewResponse

func NewResponse(req Request, success bool, txHash string, err error) Response

NewResponse creates a new response object.

type ResponseReceiver

type ResponseReceiver struct {
	ReqType    RequestType
	ResponseCh chan Response
}

ResponseReceiver is the struct for receiving the response from the sender worker.

func NewResponseReceiver

func NewResponseReceiver(reqType RequestType) ResponseReceiver

NewResponseReceiver creates a new response receiver for a request type.

Jump to

Keyboard shortcuts

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