servers

package
v1.0.60 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoSuchRepeater    = errors.New("no such repeater")
	ErrUnmarshalRepeater = errors.New("unmarshal repeater")
	ErrCastRepeater      = errors.New("unable to cast repeater id")
	ErrNoSuchPeer        = errors.New("no such peer")
	ErrUnmarshalPeer     = errors.New("unmarshal peer")
)

Functions

This section is empty.

Types

type DMRServer

type DMRServer interface {
	Start(ctx context.Context)
	Stop(ctx context.Context)
	TrackCall(ctx context.Context, packet models.Packet, isVoice bool)
}

type RedisClient added in v1.0.38

type RedisClient struct {
	Redis *redis.Client
}

func MakeRedisClient added in v1.0.38

func MakeRedisClient(redis *redis.Client) *RedisClient

func (*RedisClient) DeleteRepeater added in v1.0.38

func (s *RedisClient) DeleteRepeater(ctx context.Context, repeaterID uint) bool

func (*RedisClient) GetPeer added in v1.0.38

func (s *RedisClient) GetPeer(ctx context.Context, peerID uint) (models.Peer, error)

func (*RedisClient) GetRepeater added in v1.0.38

func (s *RedisClient) GetRepeater(ctx context.Context, repeaterID uint) (models.Repeater, error)

func (*RedisClient) ListRepeaters added in v1.0.38

func (s *RedisClient) ListRepeaters(ctx context.Context) ([]uint, error)

func (*RedisClient) RepeaterExists added in v1.0.38

func (s *RedisClient) RepeaterExists(ctx context.Context, repeaterID uint) bool

func (*RedisClient) StoreRepeater added in v1.0.38

func (s *RedisClient) StoreRepeater(ctx context.Context, repeaterID uint, repeater models.Repeater)

func (*RedisClient) UpdateRepeaterConnection added in v1.0.38

func (s *RedisClient) UpdateRepeaterConnection(ctx context.Context, repeaterID uint, connection string)

func (*RedisClient) UpdateRepeaterPing added in v1.0.38

func (s *RedisClient) UpdateRepeaterPing(ctx context.Context, repeaterID uint)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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