Help us shape the future of Go! Take the 2026 Go Developer Survey

api

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: MIT Imports: 11 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

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

func NewAPI

func NewAPI(sessions *session.Registry, logger *logrus.Logger, authentication Authentication) *API

func (*API) Accept

func (a *API) Accept() error

func (*API) Close

func (a *API) Close() error

func (*API) Listen

func (a *API) Listen(addr string) error

type Authentication added in v0.0.4

type Authentication interface {
	Authenticate(token string) bool
}

type Client added in v0.0.11

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

func NewClient added in v0.0.11

func NewClient(conn net.Conn, pool packet.Pool) *Client

func (*Client) ReadPacket added in v0.0.11

func (c *Client) ReadPacket() (pk packet.Packet, err error)

func (*Client) WritePacket added in v0.0.11

func (c *Client) WritePacket(pk packet.Packet) error

type SecretBasedAuthentication added in v0.0.5

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

func NewSecretBasedAuthentication added in v0.0.5

func NewSecretBasedAuthentication(secret string) *SecretBasedAuthentication

func (*SecretBasedAuthentication) Authenticate added in v0.0.5

func (authentication *SecretBasedAuthentication) Authenticate(token string) bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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