c2smodel

package
v0.54.1 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Info

type Info struct {
	M map[string]string
}

Info represents C2S immutable info set.

func (Info) Bool

func (i Info) Bool(k string) bool

Bool returns bool value associated to k key.

func (Info) Float

func (i Info) Float(k string) float64

Float returns float64 value associated to k key.

func (Info) Int

func (i Info) Int(k string) int

Int returns int value associated to k key.

func (Info) String

func (i Info) String(k string) string

String returns string value associated to k key.

type Resource

type Resource struct {
	InstanceID string
	JID        *jid.JID
	Presence   *stravaganza.Presence
	Info       Info
}

Resource represents a resource entity.

func (*Resource) IsAvailable

func (r *Resource) IsAvailable() bool

IsAvailable returns presence available value.

func (*Resource) Priority

func (r *Resource) Priority() int8

Priority returns resource presence priority.

Jump to

Keyboard shortcuts

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