utils

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: May 2, 2023 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version string

The executable's version string with no leading 'v' (e.g. "1.0.0" or "1.0.1-g1a2b3c4d").

Functions

func GetDependency

func GetDependency[T interface{}](ctx context.Context, d *DependencyContainer) T

func GetFlagValue

func GetFlagValue[T any](parser argParser, name string) T

func WebServerFlags

func WebServerFlags(parser argParser) (*flag.FlagSet, func(context.Context))

Types

type CronHelper

type CronHelper interface {
	SetCronSchedule(ctx context.Context) error
}

type DependencyContainer

type DependencyContainer struct {
	// contains filtered or unexported fields
}

Contains lazily generated singletons of stateless struct used throughout the application. Thread-safe.

func BuildGitBundleServerContainer

func BuildGitBundleServerContainer(logger log.TraceLogger) *DependencyContainer

func NewDependencyContainer

func NewDependencyContainer() *DependencyContainer

func (*DependencyContainer) InvokeAll

func (d *DependencyContainer) InvokeAll(ctx context.Context)

func (*DependencyContainer) ListRegisteredTypes

func (d *DependencyContainer) ListRegisteredTypes() []reflect.Type

type Initializer

type Initializer[T interface{}] func(ctx context.Context) T

Jump to

Keyboard shortcuts

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