relay

package
v0.0.0-...-6af2dc9 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2021 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClient

func NewClient(config *configure.Config)

func NewServer

func NewServer(config *configure.Config)

Types

type Client

type Client struct {
	*base.Client
	// contains filtered or unexported fields
}

func (*Client) GetSettings

func (c *Client) GetSettings(ctx context.Context, relay string) (HttpSettingsResp, error)

func (*Client) GetTokens

func (c *Client) GetTokens(ctx context.Context, relay string, count int) ([]string, error)

func (*Client) HandleTCP

func (c *Client) HandleTCP(ctx context.Context)

func (*Client) HandleUDP

func (c *Client) HandleUDP(ctx context.Context)

type HttpSettingsResp

type HttpSettingsResp struct {
	AccessPoints []string `json:"access_points"`
}

type Server

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

func (*Server) HttpHandler

func (r *Server) HttpHandler(ctx *fasthttp.RequestCtx)

func (*Server) ListenTCP

func (r *Server) ListenTCP(ln *net.TCPListener)

func (*Server) ProcessConn

func (r *Server) ProcessConn(nConn net.Conn)

func (*Server) ProcessSignal

func (n *Server) ProcessSignal()

func (*Server) Stop

func (r *Server) Stop()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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