Documentation
¶
Index ¶
Constants ¶
View Source
const ( PriorityLocal PriorityRemoteHttp PriorityRemoteService )
View Source
const (
ProviderName string = "chain"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type LocationPlugin ¶
type LocationPlugin interface { // Init init plugin Init(ctx *plugin.InitContext) error // GetLocation get location GetLocation() (*model.Location, error) // Name plugin name Name() string }
LocationPlugin location provider plugin
type Provider ¶
type Provider struct { *plugin.PluginBase // contains filtered or unexported fields }
Provider 从环境变量获取地域信息
func (*Provider) GetLocation ¶
GetLocation 获取地理位置信息
type ProviderType ¶
type ProviderType = string
const ( Local ProviderType = "local" RemoteHttp ProviderType = "remoteHttp" RemoteService ProviderType = "remoteService" )
Click to show internal directories.
Click to hide internal directories.