Documentation ¶
Index ¶
- Variables
- func Providers() map[string]provider.ProxyProvider
- func Proxies() map[string]C.Proxy
- func Rules() []C.Rule
- func SetMode(m TunnelMode)
- func TCPIn() chan<- C.ConnContext
- func UDPIn() chan<- *inbound.PacketAdapter
- func UpdateProxies(newProxies map[string]C.Proxy, newProviders map[string]provider.ProxyProvider)
- func UpdateRules(newRules []C.Rule)
- type TunnelMode
Constants ¶
This section is empty.
Variables ¶
View Source
var ModeMapping = map[string]TunnelMode{ Global.String(): Global, Rule.String(): Rule, Direct.String(): Direct, }
ModeMapping is a mapping for Mode enum
View Source
var ( // experimental feature UDPFallbackMatch = atomic.NewBool(false) )
Functions ¶
func Providers ¶ added in v0.18.0
func Providers() map[string]provider.ProxyProvider
Providers return all compatible providers
func UDPIn ¶ added in v1.6.5
func UDPIn() chan<- *inbound.PacketAdapter
UDPIn return fan-in udp queue
func UpdateProxies ¶ added in v0.18.0
UpdateProxies handle update proxies
func UpdateRules ¶ added in v0.18.0
UpdateRules handle update rules
Types ¶
type TunnelMode ¶ added in v0.18.0
type TunnelMode int
const ( Global TunnelMode = iota Rule Direct )
func (TunnelMode) MarshalJSON ¶ added in v0.18.0
func (m TunnelMode) MarshalJSON() ([]byte, error)
MarshalJSON serialize Mode
func (TunnelMode) MarshalYAML ¶ added in v0.19.0
func (m TunnelMode) MarshalYAML() (any, error)
MarshalYAML serialize TunnelMode with yaml
func (TunnelMode) String ¶ added in v0.18.0
func (m TunnelMode) String() string
func (*TunnelMode) UnmarshalJSON ¶ added in v0.18.0
func (m *TunnelMode) UnmarshalJSON(data []byte) error
UnmarshalJSON unserialize Mode
func (*TunnelMode) UnmarshalYAML ¶ added in v0.18.0
func (m *TunnelMode) UnmarshalYAML(unmarshal func(any) error) error
UnmarshalYAML unserialize Mode with yaml
Click to show internal directories.
Click to hide internal directories.