xep0280

package
v0.59.0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ModuleName represents carbons module name.
	ModuleName = "carbons"

	// XEPNumber represents carbons XEP number.
	XEPNumber = "0280"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Carbons

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

Carbons represents carbons (XEP-0280) module type.

func New

func New(
	router router.Router,
	hosts *host.Hosts,
	resMng resourcemanager.Manager,
	hk *hook.Hooks,
	logger kitlog.Logger,
) *Carbons

New returns a new initialized carbons instance.

func (*Carbons) AccountFeatures

func (p *Carbons) AccountFeatures(_ context.Context) ([]string, error)

AccountFeatures returns ping account disco features.

func (*Carbons) MatchesNamespace

func (p *Carbons) MatchesNamespace(namespace string, serverTarget bool) bool

MatchesNamespace tells whether namespace matches carbons module.

func (*Carbons) Name

func (p *Carbons) Name() string

Name returns carbons module name.

func (*Carbons) ProcessIQ

func (p *Carbons) ProcessIQ(ctx context.Context, iq *stravaganza.IQ) error

ProcessIQ process a carbons iq.

func (*Carbons) ServerFeatures

func (p *Carbons) ServerFeatures(_ context.Context) ([]string, error)

ServerFeatures returns carbons server disco features.

func (*Carbons) Start

func (p *Carbons) Start(_ context.Context) error

Start starts carbons module.

func (*Carbons) Stop

func (p *Carbons) Stop(_ context.Context) error

Stop stops carbons module.

func (*Carbons) StreamFeature

func (p *Carbons) StreamFeature(_ context.Context, _ string) (stravaganza.Element, error)

StreamFeature returns carbons module stream feature.

Jump to

Keyboard shortcuts

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