Documentation ¶
Index ¶
- func AddPortsToFirewall(ports []int)
- func ExtractIP(ipStrings string) ([]string, error)
- func FilterNotEmpty(item string) bool
- func FormatAddress(addr string) string
- func IsLocalIP(ip net.IP) bool
- func JSONClone(v interface{}) (interface{}, error)
- func JSONDecodeConfig(data []byte, ptr any) (encodeJSON []byte, err error)
- func JSONIsNull(jsonData []byte) bool
- func LookupCNAME(host string) (string, error)
- func MapAddPrefixFunc(prefix string) func(item string) string
- func NextIP(prevIP net.IP) net.IP
- func ParseIPValue(value string) (newValue string, ipFrom string, ipTo string, ok bool)
- func PrintError(err error)
- func RangeTimes(timeFrom string, timeTo string, everyMinutes int32) (result []string, err error)
- func Recover()
- func SplitNumbers(numbers string) (result []int64)
- func ValidateEmail(email string) bool
- type ServiceManager
- func (this *ServiceManager) Close() error
- func (this *ServiceManager) Install(exePath string, args []string) error
- func (this *ServiceManager) Log(msg string)
- func (this *ServiceManager) LogError(msg string)
- func (this *ServiceManager) PauseWindow()
- func (this *ServiceManager) Start() error
- func (this *ServiceManager) Uninstall() error
- type StringsStream
- type Ticker
- type Unzip
- type UpgradeFileWriter
- type UpgradeManager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddPortsToFirewall ¶ added in v0.4.7
func AddPortsToFirewall(ports []int)
func FilterNotEmpty ¶ added in v0.5.2
func JSONClone ¶ added in v0.4.5
func JSONClone(v interface{}) (interface{}, error)
JSONClone 使用JSON克隆对象
func JSONDecodeConfig ¶ added in v1.2.7
JSONDecodeConfig 解码并重新编码 是为了去除原有JSON中不需要的数据
func MapAddPrefixFunc ¶ added in v0.5.2
func ParseIPValue ¶ added in v1.3.5
ParseIPValue 解析IP值
func PrintError ¶
func PrintError(err error)
func RangeTimes ¶ added in v0.5.8
RangeTimes 计算时间点
Types ¶
type ServiceManager ¶
type ServiceManager struct { Name string Description string // contains filtered or unexported fields }
服务管理器
type StringsStream ¶ added in v0.5.2
type StringsStream struct {
// contains filtered or unexported fields
}
func NewStringsStream ¶ added in v0.5.2
func NewStringsStream(s []string) *StringsStream
func (*StringsStream) Filter ¶ added in v0.5.2
func (this *StringsStream) Filter(f ...func(item string) bool) *StringsStream
func (*StringsStream) Map ¶ added in v0.5.2
func (this *StringsStream) Map(f ...func(item string) string) *StringsStream
func (*StringsStream) Result ¶ added in v0.5.2
func (this *StringsStream) Result() []string
func (*StringsStream) Unique ¶ added in v0.5.2
func (this *StringsStream) Unique() *StringsStream
type UpgradeFileWriter ¶ added in v0.5.3
type UpgradeFileWriter struct {
// contains filtered or unexported fields
}
func NewUpgradeFileWriter ¶ added in v0.5.3
func NewUpgradeFileWriter(rawWriter io.Writer) *UpgradeFileWriter
func (*UpgradeFileWriter) TotalWritten ¶ added in v0.5.3
func (this *UpgradeFileWriter) TotalWritten() int64
type UpgradeManager ¶ added in v0.5.3
type UpgradeManager struct {
// contains filtered or unexported fields
}
func NewUpgradeManager ¶ added in v0.5.3
func NewUpgradeManager(component string, downloadURL string) *UpgradeManager
func (*UpgradeManager) Cancel ¶ added in v0.5.3
func (this *UpgradeManager) Cancel() error
func (*UpgradeManager) IsDownloading ¶ added in v0.5.3
func (this *UpgradeManager) IsDownloading() bool
func (*UpgradeManager) NewVersion ¶ added in v0.5.3
func (this *UpgradeManager) NewVersion() string
func (*UpgradeManager) Progress ¶ added in v0.5.3
func (this *UpgradeManager) Progress() float32
func (*UpgradeManager) Start ¶ added in v0.5.3
func (this *UpgradeManager) Start() error
Source Files ¶
Click to show internal directories.
Click to hide internal directories.