requests

package
v0.0.0-...-7034edb Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AnswersRoutingKey = "answers.*"
	AnswersQueueName  = "answers"
)

Variables

This section is empty.

Functions

func GetBinding

func GetBinding() amqp.Binding

Types

type RequestCallback

type RequestCallback func(ctx context.Context, s *discordgo.Session,
	i *discordgo.InteractionCreate, message *amqp.RabbitMQMessage, properties map[string]any)

type RequestManager

type RequestManager interface {
	Request(s *discordgo.Session, i *discordgo.InteractionCreate, routingKey string,
		message *amqp.RabbitMQMessage, callback RequestCallback, properties ...map[string]any) error
	Listen() error
}

type RequestManagerImpl

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

func New

func (*RequestManagerImpl) Listen

func (manager *RequestManagerImpl) Listen() error

func (*RequestManagerImpl) Request

func (manager *RequestManagerImpl) Request(s *discordgo.Session, i *discordgo.InteractionCreate,
	routingKey string, message *amqp.RabbitMQMessage, callback RequestCallback,
	optionalProperties ...map[string]any) error

Jump to

Keyboard shortcuts

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