services

package
v0.0.12 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventService

type EventService struct {
	EventStorage interfaces.EventStorage
}

func (*EventService) CreateEvent

func (es *EventService) CreateEvent(ctx context.Context, event *models.Event) (*models.Event, error)

func (*EventService) DeleteEvent added in v0.0.2

func (es *EventService) DeleteEvent(ctx context.Context, id, owner string) error

func (*EventService) DeleteEventsOlderDate added in v0.0.8

func (es *EventService) DeleteEventsOlderDate(ctx context.Context, date *time.Time, owner string) error

func (*EventService) GetEvent added in v0.0.4

func (es *EventService) GetEvent(ctx context.Context, id, owner string) (*models.Event, error)

func (*EventService) ListEvents added in v0.0.4

func (es *EventService) ListEvents(ctx context.Context, owner string, startTime *time.Time) ([]*models.Event, error)

func (*EventService) UpdateEvent added in v0.0.4

func (es *EventService) UpdateEvent(ctx context.Context, owner, title, text, id string, startTime, endTime *time.Time) (*models.Event, error)

type NotificatorService added in v0.0.6

type NotificatorService struct {
	EventStorage interfaces.EventStorage
	TaskQueue    interfaces.TaskQueue
	Period       time.Duration
	QName        string
	Exchange     string
}

func (*NotificatorService) ScanEvents added in v0.0.6

func (n *NotificatorService) ScanEvents(ctx context.Context) error

func (*NotificatorService) ServeNotificator added in v0.0.7

func (n *NotificatorService) ServeNotificator(ctx context.Context) error

type SenderService added in v0.0.7

type SenderService struct {
	Sender    interfaces.EventSender
	TaskQueue interfaces.TaskQueue
	QName     string
}

func (*SenderService) SendNotification added in v0.0.7

func (s *SenderService) SendNotification(ctx context.Context, event *models.Event) error

func (*SenderService) Serve added in v0.0.7

func (s *SenderService) Serve(ctx context.Context) error

Jump to

Keyboard shortcuts

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