this repo has no description
1package notify 2 3import ( 4 "context" 5 6 "tangled.org/core/appview/models" 7) 8 9type Notifier interface { 10 NewRepo(ctx context.Context, repo *models.Repo) 11 12 NewStar(ctx context.Context, star *models.Star) 13 DeleteStar(ctx context.Context, star *models.Star) 14 15 NewIssue(ctx context.Context, issue *models.Issue) 16 NewIssueComment(ctx context.Context, comment *models.IssueComment) 17 NewIssueState(ctx context.Context, issue *models.Issue) 18 DeleteIssue(ctx context.Context, issue *models.Issue) 19 20 NewFollow(ctx context.Context, follow *models.Follow) 21 DeleteFollow(ctx context.Context, follow *models.Follow) 22 23 NewPull(ctx context.Context, pull *models.Pull) 24 NewPullComment(ctx context.Context, comment *models.PullComment) 25 NewPullMerged(ctx context.Context, pull *models.Pull) 26 NewPullClosed(ctx context.Context, pull *models.Pull) 27 NewPullReopen(ctx context.Context, pull *models.Pull) 28 29 UpdateProfile(ctx context.Context, profile *models.Profile) 30 31 NewString(ctx context.Context, s *models.String) 32 EditString(ctx context.Context, s *models.String) 33 DeleteString(ctx context.Context, did, rkey string) 34} 35 36// BaseNotifier is a listener that does nothing 37type BaseNotifier struct{} 38 39var _ Notifier = &BaseNotifier{} 40 41func (m *BaseNotifier) NewRepo(ctx context.Context, repo *models.Repo) {} 42 43func (m *BaseNotifier) NewStar(ctx context.Context, star *models.Star) {} 44func (m *BaseNotifier) DeleteStar(ctx context.Context, star *models.Star) {} 45 46func (m *BaseNotifier) NewIssue(ctx context.Context, issue *models.Issue) {} 47func (m *BaseNotifier) NewIssueComment(ctx context.Context, comment *models.IssueComment) {} 48func (m *BaseNotifier) NewIssueState(ctx context.Context, issue *models.Issue) {} 49func (m *BaseNotifier) DeleteIssue(ctx context.Context, issue *models.Issue) {} 50 51func (m *BaseNotifier) NewFollow(ctx context.Context, follow *models.Follow) {} 52func (m *BaseNotifier) DeleteFollow(ctx context.Context, follow *models.Follow) {} 53 54func (m *BaseNotifier) NewPull(ctx context.Context, pull *models.Pull) {} 55func (m *BaseNotifier) NewPullComment(ctx context.Context, models *models.PullComment) {} 56func (m *BaseNotifier) NewPullMerged(ctx context.Context, pull *models.Pull) {} 57func (m *BaseNotifier) NewPullClosed(ctx context.Context, pull *models.Pull) {} 58func (m *BaseNotifier) NewPullReopen(ctx context.Context, pull *models.Pull) {} 59 60func (m *BaseNotifier) UpdateProfile(ctx context.Context, profile *models.Profile) {} 61 62func (m *BaseNotifier) NewString(ctx context.Context, s *models.String) {} 63func (m *BaseNotifier) EditString(ctx context.Context, s *models.String) {} 64func (m *BaseNotifier) DeleteString(ctx context.Context, did, rkey string) {}