Documentation
¶
Index ¶
- type RedisService
- func (redis *RedisService) AddToContactList(username, contactUsername string) error
- func (redisC *RedisService) FetchChatBetween(username1, username2 string) ([]api_structure.Chat, error)
- func (redis *RedisService) FetchContactList(username string) ([]string, error)
- func (redisC *RedisService) IsUserAuthentic(user *api_structure.User) error
- func (redisC *RedisService) IsUserExist(username string) (bool, error)
- func (redisC *RedisService) RegisterNewUser(user *api_structure.User) error
- func (redisC *RedisService) SaveChatHistory(msg api_structure.Chat) error
- type UserModel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisService ¶
type RedisService struct{ Client *redis.Client }
func (*RedisService) AddToContactList ¶
func (redis *RedisService) AddToContactList(username, contactUsername string) error
func (*RedisService) FetchChatBetween ¶
func (redisC *RedisService) FetchChatBetween(username1, username2 string) ([]api_structure.Chat, error)
func (*RedisService) FetchContactList ¶
func (redis *RedisService) FetchContactList(username string) ([]string, error)
Kullanıcının Kişi Listesini Getir. Kişiye gönderilen ve kişi tarafından alınan tüm mesajları içerir. Bir kişiyle son aktiviteye göre sıralanmış bir liste döndürür
func (*RedisService) IsUserAuthentic ¶
func (redisC *RedisService) IsUserAuthentic(user *api_structure.User) error
func (*RedisService) IsUserExist ¶
func (redisC *RedisService) IsUserExist(username string) (bool, error)
func (*RedisService) RegisterNewUser ¶
func (redisC *RedisService) RegisterNewUser(user *api_structure.User) error
func (*RedisService) SaveChatHistory ¶
func (redisC *RedisService) SaveChatHistory(msg api_structure.Chat) error
Sohbeti kaydet
type UserModel ¶
type UserModel struct {
Scv RedisService
}
func (*UserModel) Login ¶
func (redisModel *UserModel) Login(user *api_structure.User) *api_structure.Response
func (*UserModel) Register ¶
func (redisModel *UserModel) Register(user *api_structure.User) *api_structure.Response
Click to show internal directories.
Click to hide internal directories.