Documentation
¶
Index ¶
- type Consensus
- type Distributed
- func (m *Distributed) ChangeThreadParent(ctx context.Context, id, userID, parentID int64) (err error)
- func (m *Distributed) DeleteFiles(ctx context.Context, ids []int64, userID int64) (err error)
- func (m *Distributed) DeleteMessage(ctx context.Context, id, userID int64) (err error)
- func (m *Distributed) DeleteThread(ctx context.Context, id, userID int64) (err error)
- func (m *Distributed) DeleteTranslation(ctx context.Context, messageID int64, lang string) (err error)
- func (m *Distributed) GetServers(ctx context.Context) ([]*api.Server, error)
- func (m *Distributed) PrivateFiles(ctx context.Context, ids []int64, userID int64, updatedAt string) (err error)
- func (m *Distributed) PrivateMessages(ctx context.Context, ids []int64, userID int64, updatedAt string) (err error)
- func (m *Distributed) PrivateThread(ctx context.Context, id, userID int64, updatedAt string) (err error)
- func (m *Distributed) PublishFiles(ctx context.Context, ids []int64, userID int64, updatedAt string) (err error)
- func (m *Distributed) PublishMessages(ctx context.Context, ids []int64, userID int64, updatedAt string) (err error)
- func (m *Distributed) PublishThread(ctx context.Context, id, userID int64, updatedAt string) (err error)
- func (m *Distributed) SaveFile(ctx context.Context, id, userID int64, name, description, mime string, ...) (err error)
- func (m *Distributed) SaveMessage(ctx context.Context, id, userID int64, name, title, text string, private bool, ...) (err error)
- func (m *Distributed) SaveThread(ctx context.Context, id, userID, parentID int64, name, description string, ...) (err error)
- func (m *Distributed) SaveTranslation(ctx context.Context, userID, messageID int64, lang string, title, text string, ...) (err error)
- func (m *Distributed) SearchMessages(ctx context.Context, userID int64, substr string, threadID int64, public int) (list []*model.Message, err error)
- func (m *Distributed) UpdateMessage(ctx context.Context, id, userID int64, name, title, text *string, ...) (err error)
- func (m *Distributed) UpdateThread(ctx context.Context, id, userID int64, name, description *string, ...) (err error)
- func (m *Distributed) UpdateTranslation(ctx context.Context, messageID int64, lang string, title, text *string, ...) (err error)
- type FilesRepository
- type MessagesRepository
- type ThreadsRepository
- type TranslationsRepository
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Distributed ¶
type Distributed struct {
// contains filtered or unexported fields
}
func New ¶
func New(consensus Consensus, messagesRepo MessagesRepository, filesRepo FilesRepository, threadsRepo ThreadsRepository, translationsRepo TranslationsRepository, log *logger.Logger) *Distributed
func (*Distributed) ChangeThreadParent ¶
func (m *Distributed) ChangeThreadParent(ctx context.Context, id, userID, parentID int64) (err error)
func (*Distributed) DeleteFiles ¶
func (*Distributed) DeleteMessage ¶
func (m *Distributed) DeleteMessage(ctx context.Context, id, userID int64) (err error)
func (*Distributed) DeleteThread ¶
func (m *Distributed) DeleteThread(ctx context.Context, id, userID int64) (err error)
func (*Distributed) DeleteTranslation ¶
func (*Distributed) GetServers ¶
func (*Distributed) PrivateFiles ¶
func (*Distributed) PrivateMessages ¶
func (*Distributed) PrivateThread ¶
func (*Distributed) PublishFiles ¶
func (*Distributed) PublishMessages ¶
func (*Distributed) PublishThread ¶
func (*Distributed) SaveMessage ¶
func (*Distributed) SaveThread ¶
func (*Distributed) SaveTranslation ¶
func (*Distributed) SearchMessages ¶
func (*Distributed) UpdateMessage ¶
func (*Distributed) UpdateThread ¶
func (*Distributed) UpdateTranslation ¶
type FilesRepository ¶
type FilesRepository interface {
}
type MessagesRepository ¶
type ThreadsRepository ¶
type TranslationsRepository ¶
Click to show internal directories.
Click to hide internal directories.