xep0092

package
v0.52.2 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

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

	// XEPNumber represents version XEP number.
	XEPNumber = "0092"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Options added in v0.52.2

type Options struct {
	// ShowOS tells whether OS info should be revealed or not.
	ShowOS bool
}

Options contains version module configuration options.

type Version

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

Version represents a version (XEP-0092) module type.

func New

func New(router router.Router, opts Options) *Version

New returns a new initialized version instance.

func (*Version) AccountFeatures added in v0.52.2

func (v *Version) AccountFeatures(_ context.Context) ([]string, error)

AccountFeatures returns version account disco features.

func (*Version) MatchesNamespace added in v0.52.2

func (v *Version) MatchesNamespace(namespace string) bool

MatchesNamespace tells whether namespace matches version module.

func (*Version) Name added in v0.52.2

func (v *Version) Name() string

Name returns version module name.

func (*Version) ProcessIQ

func (v *Version) ProcessIQ(ctx context.Context, iq *stravaganza.IQ) error

ProcessIQ process a version iq.

func (*Version) ServerFeatures added in v0.52.2

func (v *Version) ServerFeatures(_ context.Context) ([]string, error)

ServerFeatures returns version server disco features.

func (*Version) Start added in v0.52.2

func (v *Version) Start(ctx context.Context) error

Start starts version module.

func (*Version) Stop added in v0.52.2

func (v *Version) Stop(_ context.Context) error

Stop stops version module.

func (*Version) StreamFeature added in v0.52.2

func (v *Version) StreamFeature(_ context.Context, _ string) (stravaganza.Element, error)

StreamFeature returns version module stream feature.

Jump to

Keyboard shortcuts

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