articles

package
v0.0.0-...-e249f0d Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArticleCommandHandler

type ArticleCommandHandler struct{}

func NewArticleCommandHandler

func NewArticleCommandHandler() *ArticleCommandHandler

func (*ArticleCommandHandler) Handle

func (ach *ArticleCommandHandler) Handle(command cqrs.CommandMessage) (interface{}, error)

type ArticleQueryHandler

type ArticleQueryHandler struct{}

func NewArticleQueryHandler

func NewArticleQueryHandler() *ArticleQueryHandler

func (*ArticleQueryHandler) Handle

func (aqh *ArticleQueryHandler) Handle(command cqrs.QueryMessage) (interface{}, error, int)

type ArticleReadModel

type ArticleReadModel struct {
	ReadModel ReadModel
}

type CreateArticleCommand

type CreateArticleCommand struct {
	ArticleForm models.ArticleForm
}

CreateArticleCommand is the struct we use to create a new command

type DeleteArticleCommand

type DeleteArticleCommand struct {
	AggregateID string
}

type EditArticleCommand

type EditArticleCommand struct {
	AggregateId string
	ArticleForm models.ArticleForm
}

type GetArticleByAggregateIDQuery

type GetArticleByAggregateIDQuery struct {
	AggregateID string
}

type ReadModel

type ReadModel struct {
	AggregateID  string
	FinalPayload interface{}
	CreatedAt    time.Time
}

func (*ReadModel) ProjectNewReadModel

func (r *ReadModel) ProjectNewReadModel() (models.Article, error, int)

Jump to

Keyboard shortcuts

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