persistence

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2022 License: MPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var MemRepositoryFactory = RepositoryFactoryFunc(func() domain.NotificationRepository {
	return NewMemRepository()
})

Functions

This section is empty.

Types

type MemRepository

type MemRepository struct {
	// contains filtered or unexported fields
}

func NewMemRepository

func NewMemRepository() *MemRepository

func (*MemRepository) GetLastNotifications

func (r *MemRepository) GetLastNotifications(n int) []domain.Notification

func (*MemRepository) GetNotificationCount

func (r *MemRepository) GetNotificationCount() int

func (*MemRepository) GetNotifications

func (r *MemRepository) GetNotifications(from, to int) []domain.Notification

func (*MemRepository) SaveNotification

func (r *MemRepository) SaveNotification(notification domain.Notification)

type RepositoryFactoryFunc

type RepositoryFactoryFunc func() domain.NotificationRepository

func (RepositoryFactoryFunc) GetRepository

Jump to

Keyboard shortcuts

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