udp

package
v0.0.0-...-bc3f6f8 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2019 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 Network

type Network struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Network is a handel.Network implementation using UDP as its transport layer listens on 0.0.0.0

func NewNetwork

func NewNetwork(addr string, enc network.Encoding) (*Network, error)

NewNetwork creates Network baked by udp protocol

func (*Network) RegisterListener

func (udpNet *Network) RegisterListener(listener h.Listener)

RegisterListener registers listener for processing incoming packets

func (*Network) Send

func (udpNet *Network) Send(identities []h.Identity, packet *h.Packet)

Send sends a packet to supplied identities

func (*Network) Stop

func (udpNet *Network) Stop()

Stop closes

func (*Network) Values

func (udpNet *Network) Values() map[string]float64

Values implements the monitor.CounterMeasure interface

Jump to

Keyboard shortcuts

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