repository

package
v0.1.14 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FollowRepository

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

func CreateFollowRepository

func CreateFollowRepository(conn *gorm.DB) *FollowRepository

func (*FollowRepository) Create

func (f *FollowRepository) Create(entity *entity.Follow)

func (*FollowRepository) FindOneByUuid

func (f *FollowRepository) FindOneByUuid(uuid uuid.UUID) (*entity.Follow, error)

func (*FollowRepository) Save

func (f *FollowRepository) Save(follow *entity.Follow)

type NotificationRepository

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

func CreateNotificationRepository

func CreateNotificationRepository(conn *gorm.DB) *NotificationRepository

func (*NotificationRepository) AcknowledgeNotifications

func (n *NotificationRepository) AcknowledgeNotifications(userID uint, ack *model.NotificationAcknowledgement) *gorm.DB

func (*NotificationRepository) Create

func (n *NotificationRepository) Create(notification *entity.Notification) *gorm.DB

func (*NotificationRepository) FindByUser

func (n *NotificationRepository) FindByUser(user *entity.User, limit int) []*entity.Notification

func (*NotificationRepository) FindFollowNotification

func (n *NotificationRepository) FindFollowNotification(user *entity.User, following *entity.User) (*entity.Notification, error)

func (*NotificationRepository) FindPostLikeNotification

func (n *NotificationRepository) FindPostLikeNotification(user *entity.User, postUser *entity.User, link string) (*entity.Notification, error)

func (*NotificationRepository) FindReplyNotification added in v0.1.3

func (n *NotificationRepository) FindReplyNotification(user *entity.User, postUser *entity.User, link string) (*entity.Notification, error)

type PostRepository

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

func CreatePostRepository

func CreatePostRepository(conn *gorm.DB) *PostRepository

func (*PostRepository) Create

func (p *PostRepository) Create(post *entity.Post)

func (*PostRepository) FindOneByUuid

func (p *PostRepository) FindOneByUuid(uuid uuid.UUID) (*entity.Post, error)

func (*PostRepository) Save

func (p *PostRepository) Save(post *entity.Post)

type UserRepository

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

func CreateUserRepository

func CreateUserRepository(conn *gorm.DB) *UserRepository

func (*UserRepository) Create

func (u *UserRepository) Create(user *entity.User)

func (*UserRepository) FindOneByUuid

func (u *UserRepository) FindOneByUuid(uuid uuid.UUID) (*entity.User, error)

func (*UserRepository) Save

func (u *UserRepository) Save(user *entity.User)

Jump to

Keyboard shortcuts

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