Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckAddress ¶
CheckAddress checks the address work or not.
func RandomHTTPS ¶
RandomHTTPS returns a random address based on https protocol.
func SetCustomStore ¶
func SetCustomStore(s Store)
SetCustomStore replaces the default store with s.
func ValidateProxy ¶
ValidateProxy checks addresses and decides whether to store.
Types ¶
type Store ¶
type Store interface { Set(address *model.Address) error Get(key string) (*model.Address, error) GetRandOne() (*model.Address, error) GetRandHTTPS() (*model.Address, error) GetAll() ([]*model.Address, error) Delete(key string) error Update(address *model.Address) error Count() (int64, error) Close() error }
Store an object implementing Store interface can be registered with SetCustomStore to replace the default redis store.
Click to show internal directories.
Click to hide internal directories.