Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateMeetingReq ¶
type CreateMeetingReq struct { Title string `json:"title"` StartTime string `json:"starttime"` EndTime string `json:"endtime"` Participants []entities.Participant `json:"participants"` }
CreateMeetingReq represents the structure for creating a meeting
type Repository ¶
type Repository interface { CreateMeeting(CreateMeetingReq) error GetMeetingDetailsFromId(uid int) (entities.Meeting, error) GetMeetingDetailsFromTime(start, end string) ([]entities.Meeting, error) }
Repository acts as the defining layer between service(usecase and implementation)
func MakeNewMeetingRepo ¶
func MakeNewMeetingRepo(client *mongo.Client) Repository
MakeNewMeetingRepo takes and instance of mongo client and initializes the repo
type Service ¶
type Service interface { CreateMeeting(CreateMeetingReq) error GetMeetingDetailsFromId(uid int) (entities.Meeting, error) GetMeetingDetailsFromTime(start, end string) ([]entities.Meeting, error) }
Service acts as the usecase layer of clean architecture
func MakeNewMeetingService ¶
func MakeNewMeetingService(repo Repository) Service
MakeNewMeetingService provides a new instance of meeting service
Click to show internal directories.
Click to hide internal directories.