host

package
v2.14.0 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Host

type Host struct {
	Host   string
	Domain string // 可为 host,也可为 IP + 端口
}

func (*Host) Equal

func (h *Host) Equal(item provider.Item) bool

func (*Host) GetHost

func (h *Host) GetHost() string

func (*Host) GetServer

func (h *Host) GetServer() string

type Provider

type Provider interface {
	Available() (available bool, err *data.CodeError)
	Provide() (host *Host, err *data.CodeError)
	Freeze(host *Host)
}

func NewListProvider

func NewListProvider(hosts []*Host) Provider

func NewListProviderWithHostStrings

func NewListProviderWithHostStrings(hostStrings []string) Provider

Jump to

Keyboard shortcuts

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