Documentation ¶
Index ¶
- func AddUser(conn *websocket.Conn, data map[string]string)
- func DeleteUser(conn *websocket.Conn, data map[string]string)
- func FindUser(conn *websocket.Conn, data map[string]string)
- func SendBroadcast(client *e.Client, data map[string]string)
- func SendMessage(client *e.Client, data map[string]string)
- func WriteMessage(c *e.Client)
- type AddUserForm
- type Message
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteUser ¶
DeleteUser will delete a user
func WriteMessage ¶
Types ¶
type AddUserForm ¶
AddUserForm is a form of register
type Message ¶
type Message struct { ID string `json:"id"` Sender string `json:"sender"` Recipient string `json:"recipient"` Content string `json:"content"` CreatedAt string `json:"created_at"` }
Message is the struct of message
type User ¶
type User struct { UserID string `json:"id"` Username string `json:"username"` Email string `json:"email"` Password string `json:"password"` FirstName string `json:"firstName"` LastName string `json:"lastName"` ProfileImage string `json:"profileImage"` Key string `json:"key"` IsLogin bool `json:"isLogin"` }
Click to show internal directories.
Click to hide internal directories.