Documentation ¶
Index ¶
Constants ¶
View Source
const ( TypeChannel = "channel" TypeGroup = "group" TypeDirect = "direct" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChannelChatDetail ¶
type ChannelChatDetail struct { Title string `bson:"title" json:"title"` Members []primitive.ObjectID `bson:"members" json:"members"` Admins []primitive.ObjectID `bson:"admins" json:"admins"` Owner primitive.ObjectID `bson:"owner" json:"owner"` RemovedUsers []primitive.ObjectID `bson:"removed_users" json:"removedUsers"` Username string `bson:"username" json:"username"` Description string `bson:"description" json:"description"` }
type Chat ¶
type DirectChatDetail ¶
type GroupChatDetail ¶
type GroupChatDetail struct { Title string `json:"title"` Members []primitive.ObjectID `json:"members"` Admins []primitive.ObjectID `json:"admins"` Owner primitive.ObjectID `bson:"owner" json:"owner"` RemovedUsers []primitive.ObjectID `bson:"removed_users" json:"removedUsers"` Username string `json:"username"` Description string `json:"description"` }
type Repository ¶
type Service ¶
type Service interface { GetChat(staticID primitive.ObjectID) (Chat, error) CreateDirect(userStaticID primitive.ObjectID, targetStaticID primitive.ObjectID) (Chat, error) CreateGroup(userStaticID primitive.ObjectID, title string, username string, description string) (Chat, error) CreateChannel(userStaticID primitive.ObjectID, title string, username string, description string) (Chat, error) }
Click to show internal directories.
Click to hide internal directories.