dnssd

package
v0.0.0-...-f9c212a Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RR

type RR struct {
	Instance string
	Hostname string
	Domain   string
	Port     int
}

RR is a record of uptimed running on some machine on the local network

type Resolver

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

Resolver uses mDNS to find server instances.

func NewResolver

func NewResolver(hostname string) (*Resolver, error)

NewResolver creates a new mDNS Resolver

func (*Resolver) Alive

func (r *Resolver) Alive() bool

Alive returns the alive flag of the resolver

func (*Resolver) FindServer

func (r *Resolver) FindServer()

FindServer starts the Resolver's discovery process.

func (*Resolver) GetVisibleServers

func (r *Resolver) GetVisibleServers() []string

func (*Resolver) Stop

func (r *Resolver) Stop()

Stop stops the Resolver

type Server

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

Server is a type.

func CreateService

func CreateService(hostname string, port int) (*Server, error)

CreateService creates a new Server.

func (*Server) IsAlive

func (srv *Server) IsAlive() bool

IsAlive returns the Server's alive flag

func (*Server) Shutdown

func (srv *Server) Shutdown()

Shutdown tells the Server to stop publishing the uptimed service

Jump to

Keyboard shortcuts

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