client

package
v1.1.9 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2024 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetIceServers

func GetIceServers(config *config.Config, logger *slog.Logger, testRunId xid.ID) (map[string]adapters.IceServersConfig, string, error)

Types

type Client

type Client struct {
	ConnectionPair    *ConnectionPair
	OffererConnected  chan bool
	AnswererConnected chan bool

	Logger *slog.Logger

	Stats *stats.Stats
	// contains filtered or unexported fields
}

func NewClient

func NewClient(config *config.Config, iceServerInfo *stun.URI, provider string, testRunId xid.ID, testRunStartedAt time.Time, doThroughputTest bool, close chan struct{}) (c *Client, err error)

func (*Client) Run

func (c *Client) Run()

func (*Client) Stop

func (c *Client) Stop() error

type ConnectionPair

type ConnectionPair struct {
	OfferPC     *webrtc.PeerConnection
	OfferDC     *webrtc.DataChannel
	AnswerPC    *webrtc.PeerConnection
	LogOfferer  *slog.Logger
	LogAnswerer *slog.Logger
	// contains filtered or unexported fields
}

func NewConnectionPair

func NewConnectionPair(config *config.Config, iceServerInfo *stun.URI, provider string, stats *stats.Stats, doThroughputTest bool, closeChan chan struct{}) (c *ConnectionPair, err error)

type IceServersConfig added in v1.0.7

type IceServersConfig struct {
	IceServers   map[string][]webrtc.ICEServer
	DoThroughput bool
}

type PC added in v1.0.4

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

func (*PC) Stop added in v1.0.4

func (pc *PC) Stop()

Jump to

Keyboard shortcuts

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