Documentation ¶
Index ¶
- Constants
- type Options
- type Ping
- func (p *Ping) AccountFeatures(_ context.Context) ([]string, error)
- func (p *Ping) MatchesNamespace(namespace string) bool
- func (p *Ping) Name() string
- func (p *Ping) ProcessIQ(ctx context.Context, iq *stravaganza.IQ) error
- func (p *Ping) ServerFeatures(_ context.Context) ([]string, error)
- func (p *Ping) Start(_ context.Context) error
- func (p *Ping) Stop(_ context.Context) error
- func (p *Ping) StreamFeature(_ context.Context, _ string) (stravaganza.Element, error)
Constants ¶
View Source
const ( // ModuleName represents ping module name. ModuleName = "ping" // XEPNumber represents ping XEP number. XEPNumber = "0199" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Options ¶ added in v0.52.2
type Options struct { // AckTimeout tells how long should we wait until considering a client to be disconnected. AckTimeout time.Duration // Interval tells how often pings should be sent to clients. Interval time.Duration // SendPings tells whether or not server pings should be sent. SendPings bool // TimeoutAction specifies the action to be taken when a client is considered as disconnected. TimeoutAction string }
Options contains ping module configuration options.
type Ping ¶
type Ping struct {
// contains filtered or unexported fields
}
Ping represents ping (XEP-0199) module type.
func (*Ping) AccountFeatures ¶ added in v0.52.2
AccountFeatures returns ping account disco features.
func (*Ping) MatchesNamespace ¶ added in v0.52.2
MatchesNamespace tells whether namespace matches ping module.
func (*Ping) ServerFeatures ¶ added in v0.52.2
ServerFeatures returns ping server disco features.
func (*Ping) StreamFeature ¶ added in v0.52.2
StreamFeature returns ping module stream feature.
Click to show internal directories.
Click to hide internal directories.