core/internal/domain/null.go

17 lines
258 B
Go

package domain
import "time"
type NullValue[T any] struct {
V T
Valid bool // Valid is true if V is not NULL
}
type NullInt = NullValue[int]
type NullString = NullValue[string]
type NullBool = NullValue[bool]
type NullTime = NullValue[time.Time]