router

package
v0.4.5 Latest Latest
Warning

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

Go to latest
Published: May 7, 2020 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NewRouter func(config *conf.RouterConfig) (Router, error) = NewEmptyRouter

Functions

This section is empty.

Types

type EmptyRouter

type EmptyRouter struct{}

func (*EmptyRouter) RouteRequest

func (r *EmptyRouter) RouteRequest(req *protocol.Request) (Policy, error)

type Policy

type Policy int
const (
	Proxy Policy = iota
	Bypass
	Block
	Unknown

	Match
	NonMatch
)

type Router

type Router interface {
	RouteRequest(*protocol.Request) (Policy, error)
}

func NewEmptyRouter added in v0.4.2

func NewEmptyRouter(*conf.RouterConfig) (Router, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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