Documentation
¶
Index ¶
- func ConsoleLogLevel(test, debug bool) esl.Level
- func OptInAgreement(v OptIn) app_msg.Message
- func OptInDescription(v OptIn) app_msg.Message
- func OptInDisclaimer(v OptIn) app_msg.Message
- func OptInFrom(v map[string]interface{}, oi OptIn) error
- func OptInName(v OptIn) string
- type Feature
- type OptIn
- type OptInStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConsoleLogLevel ¶
func OptInAgreement ¶
func OptInDescription ¶
func OptInDisclaimer ¶
Types ¶
type Feature ¶
type Feature interface {
IsProduction() bool
IsDebug() bool
IsVerbose() bool
IsTest() bool
IsTestWithMock() bool
IsTestWithSeqReplay() (replay []nw_replay.Response, enabled bool)
IsTestWithReplay() (replay kv_storage.Storage, enabled bool)
IsQuiet() bool
IsSecure() bool
IsAutoOpen() bool
IsTransient() bool
// Is the experiment enabled or not.
Experiment(name string) bool
// UI format
UIFormat() string
// Concurrency configuration.
Concurrency() int
// Toolbox home path. Returns empty if a user doesn't specify the path.
Home() string
// Budget for memory usage
BudgetMemory() app_budget.Budget
// Budget for storage usage
BudgetStorage() app_budget.Budget
// Retrieve feature
OptInGet(oi OptIn) (f OptIn, found bool)
// Update opt-in feature
OptInUpdate(oi OptIn) error
// With test mode
AsTest(useMock bool) Feature
// With sequential replay test
AsSeqReplayTest(replay []nw_replay.Response) Feature
// With replay test
AsReplayTest(replays kv_storage.Storage) Feature
// With quiet mode, but this will not guarantee UI/log are converted into quiet mode.
AsQuiet() Feature
// Console log level
ConsoleLogLevel() esl.Level
// Extra options
Extra() app_opt.ExtraOpts
}
type OptInStatus ¶
type OptInStatus struct {
// The timestamp of opt-in, in ISO8601 format.
Timestamp string `json:"timestamp"`
// Name of the user who opt'ed in
User string `json:"user"`
// Opt-in status.
Status bool `json:"status"`
}
func (*OptInStatus) OptInCommit ¶
func (z *OptInStatus) OptInCommit(enable bool)
func (OptInStatus) OptInIsEnabled ¶
func (z OptInStatus) OptInIsEnabled() bool
func (OptInStatus) OptInTimestamp ¶
func (z OptInStatus) OptInTimestamp() string
func (OptInStatus) OptInUser ¶
func (z OptInStatus) OptInUser() string
Click to show internal directories.
Click to hide internal directories.