subscription

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: May 26, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateSubscriptionInput

type CreateSubscriptionInput struct {
	ID      string
	Channel string
}

type CreateSubscriptionService

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

func NewCreateSubscriptionService

func NewCreateSubscriptionService(registry SubscribeRegistry, backpressure uint) *CreateSubscriptionService

func (*CreateSubscriptionService) Create

type FrameFactory

type FrameFactory interface {
	Unsubscribe() app.FrameBuilder
}

type RemoveSubscriptionsService

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

func NewRemoveSubscriptionsService

func NewRemoveSubscriptionsService(unsubscribe Unsubscriber) *RemoveSubscriptionsService

func (*RemoveSubscriptionsService) Remove

func (service *RemoveSubscriptionsService) Remove(ctx context.Context, subscription_ids ...string) error

type SubscribeRegistry

type SubscribeRegistry interface {
	Register(*subscription.Subscription)
}

type Subscriptions

type Subscriptions interface {
	Active() []string
	Get(string) *subscription.Subscription
}

type UnsubscribeRegistry

type UnsubscribeRegistry interface {
	Remove(id string)
	Get(id string) *subscription.Subscription
}

type UnsubscribeService

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

func NewUnsubscribeService

func NewUnsubscribeService(
	subscriptions UnsubscribeRegistry,
	writer app.SendMessageService,
	authorizer app.RequestAuthorizer,
	frame FrameFactory,
) *UnsubscribeService

func (UnsubscribeService) Unsubscribe

func (service UnsubscribeService) Unsubscribe(ctx context.Context, subscription_id string) error

type Unsubscriber

type Unsubscriber interface {
	Unsubscribe(ctx context.Context, subscription_id string) error
}

Jump to

Keyboard shortcuts

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