p2p

package
v1.0.12 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type P2PServer

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

func NewP2PServer

func NewP2PServer(ctx context.Context, address string) P2PServer

func (*P2PServer) BroadcastMessage added in v1.0.7

func (p2p *P2PServer) BroadcastMessage(message string)

func (*P2PServer) ExposeFirstPeerForInput

func (p2p *P2PServer) ExposeFirstPeerForInput()

func (*P2PServer) GetConnectedClients added in v1.0.6

func (p2p *P2PServer) GetConnectedClients() map[string]*websocket.Conn

func (*P2PServer) GetConnections

func (p2p *P2PServer) GetConnections() map[string]string

func (*P2PServer) Shutdown

func (p2p *P2PServer) Shutdown()

func (*P2PServer) Start

func (p2p *P2PServer) Start(peers ...string)

func (*P2PServer) StartTls added in v1.0.8

func (p2p *P2PServer) StartTls(certFile, certKey string, peers ...string)

Jump to

Keyboard shortcuts

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