Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MongoConnect ¶
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
func (*DB) Repos ¶
func (db *DB) Repos() RepoRepository
func (*DB) Subscribers ¶
func (db *DB) Subscribers() SubscriberRepository
type RepoRepository ¶
type RepoRepository interface { Create(user *entity.Repo) (*entity.Repo, error) FindByUrlAndUserId(url string, userId string) (*entity.Repo, error) FindById(repoID string) (*entity.Repo, error) FindAll(userId string) ([]*entity.Repo, error) Delete(repoId string) error DeleteMany(userId string) error }
type Store ¶
type Store interface { Repos() RepoRepository Subscribers() SubscriberRepository }
type SubscriberRepository ¶
type SubscriberRepository interface { Create(user *entity.Subscriber) (*entity.Subscriber, error) FindByEmailAndRepoId(email string, repoId string) (*entity.Subscriber, error) FindById(subID string) (*entity.Subscriber, error) Update(subscriber *entity.Subscriber) (*entity.Subscriber, error) Confirm(subId string, confirmed bool) error GetAll() ([]*entity.Subscriber, error) FindAll(repoId string) ([]*entity.Subscriber, error) Delete(subId string) error DeleteMany(repoId string) error }
Click to show internal directories.
Click to hide internal directories.