conceptions

package
v1.2.17 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2022 License: LGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrSemaBoundary = &errSemaBoundary{}
	ErrSemaExcEntry = &errSemaExcEntry{}
)
View Source
var (
	ErrFinalized = &GraphFinalizedError{}
)

Functions

This section is empty.

Types

type Cache

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

func NewCache

func NewCache(size int) *Cache

func (*Cache) Add

func (m *Cache) Add(key, value interface{})

func (*Cache) Get

func (m *Cache) Get(key interface{}) (value interface{}, ok bool)

type CloakCache

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

func NewCloakCache

func NewCloakCache() *CloakCache

func (*CloakCache) Add

func (m *CloakCache) Add(key, value interface{})

func (*CloakCache) Get

func (m *CloakCache) Get(key interface{}) (value interface{}, ok bool)

type CycleError

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

func (*CycleError) Error

func (e *CycleError) Error() string

type DanglingedgeError

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

func (*DanglingedgeError) Error

func (e *DanglingedgeError) Error() string

type Graph

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

A minimal implementation of ASG or DAG (not too fast compare to direct mathematic formula on adjacency matrix) Since go do not provide such detailed reference design (godoc.org) Things must be done by myself, this's so called BoringALG

func (*Graph) AddVertex

func (g *Graph) AddVertex(name string, tag interface{}, subset []string) error

func (*Graph) Finalize

func (g *Graph) Finalize(duplicateTag bool) error

func (*Graph) Tags

func (g *Graph) Tags(name string) []interface{}

type GraphFinalizedError

type GraphFinalizedError struct {
}

func (*GraphFinalizedError) Error

func (e *GraphFinalizedError) Error() string

type NestedProxy

type NestedProxy struct {
	*list.List
}

socks5 and http(s) proxy chain

func InitProxies

func InitProxies() *NestedProxy

func (*NestedProxy) AddGlobalProxy

func (np *NestedProxy) AddGlobalProxy(uri *url.URL, ep *common.Endpoint)

first 'ProxyURI' in toml then global proxy stamps by order

func (*NestedProxy) AddProxy

func (np *NestedProxy) AddProxy(uri *url.URL, ep *common.Endpoint)

func (*NestedProxy) GetDialContext

func (np *NestedProxy) GetDialContext() ProxyDialContext

func (*NestedProxy) HasValue

func (np *NestedProxy) HasValue() bool

func (*NestedProxy) Merge

func (np *NestedProxy) Merge(peer *NestedProxy) *NestedProxy

global proxy stamps and non-global individual proxy stamps binding to resolvers Ex

func (*NestedProxy) UDPProxies

func (np *NestedProxy) UDPProxies() bool

type NodeRedeclarationError

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

func (*NodeRedeclarationError) Error

func (e *NodeRedeclarationError) Error() string

type ProxyDialContext

type ProxyDialContext func(ctx context.Context, ifi *string, network, addr string) (net.Conn, error)

type SemaGroup added in v1.1.14

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

func NewSemaGroup added in v1.1.14

func NewSemaGroup(threshold uint32) *SemaGroup

func (*SemaGroup) Acquire added in v1.1.14

func (sg *SemaGroup) Acquire(wait bool) error

func (*SemaGroup) BeginExclusive added in v1.1.14

func (sg *SemaGroup) BeginExclusive() bool

func (*SemaGroup) EndExclusive added in v1.1.14

func (sg *SemaGroup) EndExclusive()

func (*SemaGroup) Payload added in v1.1.14

func (sg *SemaGroup) Payload() uint32

func (*SemaGroup) Release added in v1.1.14

func (sg *SemaGroup) Release()

Jump to

Keyboard shortcuts

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