networking

package
v0.0.0-...-2924a1e Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2022 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsRemotePortOpen

func IsRemotePortOpen(ipAddress string, port string) bool

func IsTCPPortAvailable

func IsTCPPortAvailable(port int) bool

func LocalHostnames

func LocalHostnames() ([]string, error)

func LocalIP

func LocalIP() (string, error)

func RemoteHostnames

func RemoteHostnames() ([]string, error)

func RemoteIP

func RemoteIP() (string, error)

func ValidIP4

func ValidIP4(ipAddress string) bool

Types

type BroadcastHub

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

func NewBroadcastHub

func NewBroadcastHub(incoming chan []byte, outgoing chan []byte) *BroadcastHub

func (*BroadcastHub) Count

func (bh *BroadcastHub) Count() int

func (*BroadcastHub) Run

func (bh *BroadcastHub) Run()

type Client

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

func NewClient

func NewClient(host, port string, incoming, outgoing chan []byte) *Client

func (*Client) Count

func (c *Client) Count() int

func (*Client) Run

func (c *Client) Run()

type Connection

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

type Server

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

func NewServer

func NewServer(eventManager *z.EventManager, port string, incoming, outgoing chan []byte) *Server

func (*Server) Count

func (s *Server) Count() int

func (*Server) Run

func (s *Server) Run()

Jump to

Keyboard shortcuts

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