domain

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2023 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Overview

Package domain provides a set of types commonly used in the domain layer.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action[T ~string] struct {
	// contains filtered or unexported fields
}

Action represents an action done by a user at a given time.

func ActionFrom

func ActionFrom[T ~string](by T, at time.Time) (a Action[T])

Builds an action from both the user and the time, required when rehydrating the struct from the storage.

func NewAction

func NewAction[T ~string](by T) (a Action[T])

func (Action[T]) At

func (a Action[T]) At() time.Time

func (Action[T]) By

func (a Action[T]) By() T

Jump to

Keyboard shortcuts

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