Documentation
¶
Index ¶
- Constants
- type DataSource
- func (ds *DataSource) Close() error
- func (ds *DataSource) GetChatRooms(ctx context.Context, key string, limit, offset int) ([]*model.ChatRoom, error)
- func (ds *DataSource) GetContacts(ctx context.Context, key string, limit, offset int) ([]*model.Contact, error)
- func (ds *DataSource) GetMedia(ctx context.Context, _type string, key string) (*model.Media, error)
- func (ds *DataSource) GetMessages(ctx context.Context, startTime, endTime time.Time, talker string, ...) ([]*model.Message, error)
- func (ds *DataSource) GetSessions(ctx context.Context, key string, limit, offset int) ([]*model.Session, error)
- type MessageDBInfo
Constants ¶
View Source
const ( MessageFilePattern = "^MSG([0-9]?[0-9])?\\.db$" ContactFilePattern = "^MicroMsg.db$" ImageFilePattern = "^HardLinkImage\\.db$" VideoFilePattern = "^HardLinkVideo\\.db$" FileFilePattern = "^HardLinkFile\\.db$" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataSource ¶
type DataSource struct {
// contains filtered or unexported fields
}
DataSource 实现了 DataSource 接口
func (*DataSource) GetChatRooms ¶
func (ds *DataSource) GetChatRooms(ctx context.Context, key string, limit, offset int) ([]*model.ChatRoom, error)
GetChatRooms 实现获取群聊信息的方法
func (*DataSource) GetContacts ¶
func (ds *DataSource) GetContacts(ctx context.Context, key string, limit, offset int) ([]*model.Contact, error)
GetContacts 实现获取联系人信息的方法
func (*DataSource) GetMessages ¶
func (ds *DataSource) GetMessages(ctx context.Context, startTime, endTime time.Time, talker string, limit, offset int) ([]*model.Message, error)
GetMessages 实现 DataSource 接口的 GetMessages 方法
func (*DataSource) GetSessions ¶
func (ds *DataSource) GetSessions(ctx context.Context, key string, limit, offset int) ([]*model.Session, error)
GetSessions 实现获取会话信息的方法
Click to show internal directories.
Click to hide internal directories.