qcontext

package
v0.1.152 Latest Latest
Warning

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

Go to latest
Published: May 26, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAppName

func GetAppName(ctx context.Context) string

func GetAuthorizer added in v0.1.48

func GetAuthorizer(ctx context.Context) (qauthorization.Authorizer, bool)

func GetTickRate

func GetTickRate(ctx context.Context) time.Duration

Types

type ClientProvider

type ClientProvider[T any] interface {
	Client(ctx context.Context) T
}

func GetClientProvider

func GetClientProvider[T any](ctx context.Context) ClientProvider[T]

type CtxType

type CtxType string
const KeyAppHandle CtxType = "app_handle"
const KeyAppName CtxType = "app_name"
const KeyAppTickRate CtxType = "app_tick_rate"
const KeyAuthorizer CtxType = "authorizer"
const KeyClientProvider CtxType = "client_provider"

type Handle

type Handle interface {
	Ctx() context.Context
	BusyEvent() qss.Signal[time.Duration]
	DoInMainThread(func(context.Context))
	Exit()
	GetWg() *sync.WaitGroup
}

func GetHandle

func GetHandle(ctx context.Context) Handle

Jump to

Keyboard shortcuts

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