Help us shape the future of Go! Take the 2026 Go Developer Survey

app

package
v1.0.65 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2022 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const ModeDemo = "demo"
View Source
const ModeDev = "dev"
View Source
const ModeLocal = "local"
View Source
const ModeProd = "prod"
View Source
const ModeTest = "test"

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Mode           string
	Name           string
	ParallelTestID string
	Secret         string
	Flags          *Flags
	Scripts        []string
	DevPanel       *DevPanel
	RedisPools     *RedisPools
	GlobalContext  context.Context
	CancelContext  context.CancelFunc
}

func (*App) IsInDemoMode

func (app *App) IsInDemoMode() bool

func (*App) IsInDevMode added in v0.8.51

func (app *App) IsInDevMode() bool

func (*App) IsInLocalMode

func (app *App) IsInLocalMode() bool

func (*App) IsInMode

func (app *App) IsInMode(mode string) bool

func (*App) IsInProdMode

func (app *App) IsInProdMode() bool

func (*App) IsInTestMode

func (app *App) IsInTestMode() bool

type DevPanel

type DevPanel struct {
	UserEntity IDevPanelUserEntity
	Router     func(ginEngine *gin.Engine)
}

type Flags

type Flags struct {
	Registry *FlagsRegistry
}

func (*Flags) Bool

func (f *Flags) Bool(name string) bool

func (*Flags) String

func (f *Flags) String(name string) string

type FlagsRegistry

type FlagsRegistry struct {
	Flags map[string]interface{}
}

func (*FlagsRegistry) Bool

func (r *FlagsRegistry) Bool(name string, value bool, usage string)

func (*FlagsRegistry) String

func (r *FlagsRegistry) String(name string, value string, usage string)

type IDevPanelUserEntity added in v0.8.78

type IDevPanelUserEntity interface {
	beeorm.Entity
	GetUsername() string
	GetPassword() string
}

type IExit added in v0.9.49

type IExit interface {
	Valid()
	Error()
	Custom(exitCode int)
}

type IScript added in v0.9.49

type IScript interface {
	Description() string
	Run(ctx context.Context, exit IExit)
	Unique() bool
}

type Infinity added in v0.9.49

type Infinity interface {
	Infinity() bool
}

type Intermediate added in v0.9.49

type Intermediate interface {
	IsIntermediate() bool
}

type Interval added in v0.9.49

type Interval interface {
	Interval() time.Duration
}

type IntervalOptional added in v0.9.49

type IntervalOptional interface {
	IntervalActive() bool
}

type Optional added in v0.9.49

type Optional interface {
	Active() bool
}

type RedisPools added in v0.9.19

type RedisPools struct {
	Cache      string
	Persistent string
	Stream     string
	Search     string
}

Jump to

Keyboard shortcuts

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