Documentation
¶
Index ¶
- func IPCClientQuit(stopTunnelsOnQuit bool) (bool, error)
- func IPCClientUpdate() error
- func IPCServerListen(reader *os.File, writer *os.File, events *os.File, elevatedToken windows.Token) error
- func IPCServerNotifyManagerStopping()
- func IPCServerNotifyTunnelChange(name string, state TunnelState, err error)
- func IPCServerNotifyTunnelsChange()
- func IPCServerNotifyUpdateFound(state UpdateState)
- func IPCServerNotifyUpdateProgress(dp updater.DownloadProgress)
- func InitializeIPCClient(reader *os.File, writer *os.File, events *os.File)
- func InstallManager() error
- func InstallTunnel(configPath string) error
- func PipePathOfTunnel(tunnelName string) (string, error)
- func RunManager() error
- func RunTunnel(confPath string) error
- func ServiceNameOfTunnel(tunnelName string) (string, error)
- func UninstallManager() error
- func UninstallTunnel(name string) error
- type ManagerService
- func (s *ManagerService) Create(tunnelConfig conf.Config, tunnel *Tunnel) error
- func (s *ManagerService) Delete(tunnelName string, _ *uintptr) error
- func (s *ManagerService) GlobalState(_ uintptr, state *TunnelState) error
- func (s *ManagerService) Quit(stopTunnelsOnQuit bool, alreadyQuit *bool) error
- func (s *ManagerService) RuntimeConfig(tunnelName string, config *conf.Config) error
- func (s *ManagerService) Start(tunnelName string, unused *uintptr) error
- func (s *ManagerService) State(tunnelName string, state *TunnelState) error
- func (s *ManagerService) Stop(tunnelName string, _ *uintptr) error
- func (s *ManagerService) StoredConfig(tunnelName string, config *conf.Config) error
- func (s *ManagerService) Tunnels(_ uintptr, tunnels *[]Tunnel) error
- func (s *ManagerService) Update(_ uintptr, _ *uintptr) error
- func (s *ManagerService) UpdateState(_ uintptr, state *UpdateState) error
- func (s *ManagerService) WaitForStop(tunnelName string, _ *uintptr) error
- type ManagerStoppingCallback
- type NotificationType
- type Tunnel
- func (t *Tunnel) Delete() error
- func (t *Tunnel) RuntimeConfig() (c conf.Config, err error)
- func (t *Tunnel) Start() error
- func (t *Tunnel) State() (TunnelState, error)
- func (t *Tunnel) Stop() error
- func (t *Tunnel) StoredConfig() (c conf.Config, err error)
- func (t *Tunnel) Toggle() (oldState TunnelState, err error)
- func (t *Tunnel) WaitForStop() error
- type TunnelChangeCallback
- type TunnelState
- type TunnelsChangeCallback
- type UpdateFoundCallback
- type UpdateProgressCallback
- type UpdateState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IPCClientQuit ¶
func IPCClientUpdate ¶
func IPCClientUpdate() error
func IPCServerListen ¶
func IPCServerNotifyManagerStopping ¶
func IPCServerNotifyManagerStopping()
func IPCServerNotifyTunnelChange ¶
func IPCServerNotifyTunnelChange(name string, state TunnelState, err error)
func IPCServerNotifyTunnelsChange ¶
func IPCServerNotifyTunnelsChange()
func IPCServerNotifyUpdateFound ¶
func IPCServerNotifyUpdateFound(state UpdateState)
func IPCServerNotifyUpdateProgress ¶
func IPCServerNotifyUpdateProgress(dp updater.DownloadProgress)
func InitializeIPCClient ¶
func InstallManager ¶
func InstallManager() error
func InstallTunnel ¶
func PipePathOfTunnel ¶
func RunManager ¶
func RunManager() error
func ServiceNameOfTunnel ¶
func UninstallManager ¶
func UninstallManager() error
func UninstallTunnel ¶
Types ¶
type ManagerService ¶
type ManagerService struct {
// contains filtered or unexported fields
}
func (*ManagerService) Create ¶
func (s *ManagerService) Create(tunnelConfig conf.Config, tunnel *Tunnel) error
func (*ManagerService) Delete ¶
func (s *ManagerService) Delete(tunnelName string, _ *uintptr) error
func (*ManagerService) GlobalState ¶
func (s *ManagerService) GlobalState(_ uintptr, state *TunnelState) error
func (*ManagerService) Quit ¶
func (s *ManagerService) Quit(stopTunnelsOnQuit bool, alreadyQuit *bool) error
func (*ManagerService) RuntimeConfig ¶
func (s *ManagerService) RuntimeConfig(tunnelName string, config *conf.Config) error
func (*ManagerService) Start ¶
func (s *ManagerService) Start(tunnelName string, unused *uintptr) error
func (*ManagerService) State ¶
func (s *ManagerService) State(tunnelName string, state *TunnelState) error
func (*ManagerService) StoredConfig ¶
func (s *ManagerService) StoredConfig(tunnelName string, config *conf.Config) error
func (*ManagerService) Tunnels ¶
func (s *ManagerService) Tunnels(_ uintptr, tunnels *[]Tunnel) error
func (*ManagerService) UpdateState ¶
func (s *ManagerService) UpdateState(_ uintptr, state *UpdateState) error
func (*ManagerService) WaitForStop ¶
func (s *ManagerService) WaitForStop(tunnelName string, _ *uintptr) error
type ManagerStoppingCallback ¶
type ManagerStoppingCallback struct {
// contains filtered or unexported fields
}
func IPCClientRegisterManagerStopping ¶
func IPCClientRegisterManagerStopping(cb func()) *ManagerStoppingCallback
func (*ManagerStoppingCallback) Unregister ¶
func (cb *ManagerStoppingCallback) Unregister()
type NotificationType ¶
type NotificationType int
const ( TunnelChangeNotificationType NotificationType = iota TunnelsChangeNotificationType ManagerStoppingNotificationType UpdateFoundNotificationType UpdateProgressNotificationType )
type Tunnel ¶
type Tunnel struct {
Name string
}
func IPCClientTunnels ¶
func (*Tunnel) State ¶
func (t *Tunnel) State() (TunnelState, error)
func (*Tunnel) Toggle ¶
func (t *Tunnel) Toggle() (oldState TunnelState, err error)
func (*Tunnel) WaitForStop ¶
type TunnelChangeCallback ¶
type TunnelChangeCallback struct {
// contains filtered or unexported fields
}
func IPCClientRegisterTunnelChange ¶
func IPCClientRegisterTunnelChange(cb func(tunnel *Tunnel, state TunnelState, globalState TunnelState, err error)) *TunnelChangeCallback
func (*TunnelChangeCallback) Unregister ¶
func (cb *TunnelChangeCallback) Unregister()
type TunnelState ¶
type TunnelState int
const ( TunnelUnknown TunnelState = iota TunnelStarted TunnelStopped TunnelStarting TunnelStopping )
func IPCClientGlobalState ¶
func IPCClientGlobalState() (TunnelState, error)
type TunnelsChangeCallback ¶
type TunnelsChangeCallback struct {
// contains filtered or unexported fields
}
func IPCClientRegisterTunnelsChange ¶
func IPCClientRegisterTunnelsChange(cb func()) *TunnelsChangeCallback
func (*TunnelsChangeCallback) Unregister ¶
func (cb *TunnelsChangeCallback) Unregister()
type UpdateFoundCallback ¶
type UpdateFoundCallback struct {
// contains filtered or unexported fields
}
func IPCClientRegisterUpdateFound ¶
func IPCClientRegisterUpdateFound(cb func(updateState UpdateState)) *UpdateFoundCallback
func (*UpdateFoundCallback) Unregister ¶
func (cb *UpdateFoundCallback) Unregister()
type UpdateProgressCallback ¶
type UpdateProgressCallback struct {
// contains filtered or unexported fields
}
func IPCClientRegisterUpdateProgress ¶
func IPCClientRegisterUpdateProgress(cb func(dp updater.DownloadProgress)) *UpdateProgressCallback
func (*UpdateProgressCallback) Unregister ¶
func (cb *UpdateProgressCallback) Unregister()
type UpdateState ¶
type UpdateState uint32
const ( UpdateStateUnknown UpdateState = iota UpdateStateFoundUpdate UpdateStateUpdatesDisabledUnofficialBuild )
func IPCClientUpdateState ¶
func IPCClientUpdateState() (UpdateState, error)
Click to show internal directories.
Click to hide internal directories.