interfaces

package module
v0.0.0-...-447f139 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Comm

type Comm []*Remote

func LoadComm

func LoadComm(idx int, addrs []string, newAdrress *func() string, newSender *func(string) *bufio.ReadWriter, encodeNotify *func(int, string) string, timeout time.Duration) Comm

func NewComm

func NewComm(n int, newAdrress *func() string, newSender *func(string) *bufio.ReadWriter, encodeNotify *func(int, string) string, timeout time.Duration) Comm

func (*Comm) Get

func (c *Comm) Get(i int) (string, error)

func (*Comm) Replace

func (c *Comm) Replace(i int, addr string) error

func (*Comm) Send

func (c *Comm) Send(i int, msg string) error

type Remote

type Remote struct {
	Timeout     time.Duration
	NewAdrress  *func() string
	NewSender   *func(string) *bufio.ReadWriter
	NotifyReset *func(string)
	Stream      *bufio.ReadWriter
	Sent        []string
	InChannel   chan string
	Offset      int
	Received    int
}

func NewRemote

func NewRemote(newAdrress *func() string, newSender *func(string) *bufio.ReadWriter, notifyReset *func(string), timeout time.Duration) *Remote

func (*Remote) Get

func (r *Remote) Get() string

func (*Remote) Replace

func (r *Remote) Replace(addr string)

func (*Remote) Reset

func (r *Remote) Reset()

func (*Remote) Send

func (r *Remote) Send(msg string)

Jump to

Keyboard shortcuts

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