internal

package
v1.17.3 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2016 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrProxyNotFound    = errors.New("Proxy not found.")
	ErrNameExists       = errors.New("Proxy with the same name already exists.")
	ErrBadConfiguration = errors.New("Bad proxy configuration.")
)

Functions

func CreateInboundConfig added in v1.17.1

func CreateInboundConfig(protocol string, data []byte) (interface{}, error)

func CreateInboundHandler

func CreateInboundHandler(name string, space app.Space, rawConfig []byte, meta *proxy.InboundHandlerMeta) (proxy.InboundHandler, error)

func CreateOutboundConfig added in v1.17.1

func CreateOutboundConfig(protocol string, data []byte) (interface{}, error)

func CreateOutboundHandler

func CreateOutboundHandler(name string, space app.Space, rawConfig []byte, meta *proxy.OutboundHandlerMeta) (proxy.OutboundHandler, error)

func MustRegisterInboundHandlerCreator

func MustRegisterInboundHandlerCreator(name string, creator InboundHandlerFactory)

func MustRegisterOutboundHandlerCreator

func MustRegisterOutboundHandlerCreator(name string, creator OutboundHandlerFactory)

func RegisterInboundConfig added in v1.17.1

func RegisterInboundConfig(protocol string, creator loader.ConfigCreator) error

func RegisterInboundHandlerCreator

func RegisterInboundHandlerCreator(name string, creator InboundHandlerFactory) error

func RegisterOutboundConfig added in v1.17.1

func RegisterOutboundConfig(protocol string, creator loader.ConfigCreator) error

func RegisterOutboundHandlerCreator

func RegisterOutboundHandlerCreator(name string, creator OutboundHandlerFactory) error

Types

type InboundHandlerFactory added in v1.17.1

type InboundHandlerFactory interface {
	StreamCapability() internet.StreamConnectionType
	Create(space app.Space, config interface{}, meta *proxy.InboundHandlerMeta) (proxy.InboundHandler, error)
}

type OutboundHandlerFactory added in v1.17.1

type OutboundHandlerFactory interface {
	StreamCapability() internet.StreamConnectionType
	Create(space app.Space, config interface{}, meta *proxy.OutboundHandlerMeta) (proxy.OutboundHandler, error)
}

Jump to

Keyboard shortcuts

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