system

package
v0.0.0-...-72e33f6 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateEvent

func CreateEvent(ctx context.Context, db sqlite.DBTx, event Event) error

func Init

func Init(_app App)

func UpdateConfig

func UpdateConfig(arg UpdateConfigParams) error

Types

type App

type App struct {
	CP ConfigProvider
}

type Config

type Config struct {
	SiteName     string
	Location     types.Location
	Coordinates  models.Coordinate
	EnableSignUp bool
}

func GetConfig

func GetConfig() (Config, error)

type ConfigProvider

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

func NewConfigProvider

func NewConfigProvider(filePath string) (ConfigProvider, error)

func (ConfigProvider) GetConfig

func (p ConfigProvider) GetConfig() (Config, error)

func (ConfigProvider) UpdateConfig

func (p ConfigProvider) UpdateConfig(fn func(cfg Config) (Config, error)) error

type Event

type Event struct {
	Action string
	Data   []byte
}

type EventBuilder

type EventBuilder[T any] struct {
	// contains filtered or unexported fields
}

func NewEventBuilder

func NewEventBuilder[T any](action string) EventBuilder[T]

func (EventBuilder[T]) Create

func (e EventBuilder[T]) Create(data T) Event

type UpdateConfigParams

type UpdateConfigParams struct {
	SiteName     string
	EnableSignUp bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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