application

package
v0.0.0-...-70cb23a Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AppName = "app"
)

Variables

View Source
var (
	GIT_TAG    string
	GIT_COMMIT string
	GIT_BRANCH string
	BUILD_TIME string
	GO_VERSION string
)

编译时注入

Functions

func FullVersion

func FullVersion() string

FullVersion show the version info

func Short

func Short() string

Short 版本缩写

Types

type Application

type Application struct {
	ioc.ObjectImpl

	AppName        string `json:"name" yaml:"name" toml:"name" env:"APP_NAME"`
	AppDescription string `json:"description" yaml:"description" toml:"description" env:"APP_DESCRIPTION"`
	Domain         string `json:"domain" yaml:"domain" toml:"domain" env:"APP_DOMAIN"`
	EncryptKey     string `json:"encrypt_key" yaml:"encrypt_key" toml:"encrypt_key" env:"APP_ENCRYPT_KEY"`
	CipherPrefix   string `json:"cipher_prefix" yaml:"cipher_prefix" toml:"cipher_prefix" env:"APP_CIPHER_PREFIX"`
}

func Get

func Get() *Application

func (*Application) Init

func (i *Application) Init() error

func (*Application) Name

func (i *Application) Name() string

func (*Application) Priority

func (i *Application) Priority() int

优先初始化, 以供后面的组件使用

Jump to

Keyboard shortcuts

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