valueobjs

package
v0.0.1-alpha.0 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewEmail

func NewEmail(email string) (models.ValueObject[string], error)

func NewId

func NewId(id string) (models.ValueObject[string], error)

Types

type Email

type Email struct {
	Email string `validate:"email"`
}

func (*Email) IsValid

func (email *Email) IsValid() error

func (*Email) Value

func (email *Email) Value() string

type Id

type Id struct {
	Id string `validate:"uuid4"`
}

func (*Id) IsValid

func (id *Id) IsValid() error

func (*Id) Value

func (id *Id) Value() string

Jump to

Keyboard shortcuts

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