Documentation
¶
Overview ¶
TODO: Inject to a global interface e.g. command factory as soon as it exists and remove this file.
Index ¶
- func AddCondition(name, description string, conditionFunc func() bool)
- func GetGlobal() types.RemoteConfig
- func GetGlobalSponsorship() types.SponsorshipManager
- func InitGlobal(config Config, stateManager statetypes.State, isInternetActive func() bool) types.RemoteConfig
- func InitGlobalSponsorship(localPath string, stateManager statetypes.State, isInternetActive func() bool, ...) types.SponsorshipManager
- func ListConditions() (conditions map[string]string)
- func New(config *Config, stateManager statetypes.State, isInternetActive func() bool) types.RemoteConfig
- func NewSponsorshipManager(localPath string, stateManager statetypes.State, isInternetActive func() bool, ...) types.SponsorshipManager
- type Config
- type Local
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddCondition ¶
func GetGlobal ¶
func GetGlobal() types.RemoteConfig
GetGlobal returns the global remote config. Returns nil if InitGlobal was not called in advance.
func GetGlobalSponsorship ¶ added in v1.24.8
func GetGlobalSponsorship() types.SponsorshipManager
GetGlobalSponsorship returns the global sponsorship manager. Returns nil if InitGlobalSponsorship was not called in advance.
func InitGlobal ¶
func InitGlobal(config Config, stateManager statetypes.State, isInternetActive func() bool) types.RemoteConfig
InitGlobal initializes the global remote config. This is done once, subsequent calls do not have any effect.
func InitGlobalSponsorship ¶ added in v1.24.8
func InitGlobalSponsorship(localPath string, stateManager statetypes.State, isInternetActive func() bool, updateInterval int, url string) types.SponsorshipManager
InitGlobalSponsorship initializes the global sponsorship manager using a direct URL. This is done once, subsequent calls do not have any effect.
func ListConditions ¶
func New ¶
func New(config *Config, stateManager statetypes.State, isInternetActive func() bool) types.RemoteConfig
New creates and returns a new RemoteConfig.
func NewSponsorshipManager ¶ added in v1.24.8
func NewSponsorshipManager(localPath string, stateManager statetypes.State, isInternetActive func() bool, updateInterval int, url string) types.SponsorshipManager
NewSponsorshipManager creates a new sponsorship data manager using a direct URL