Documentation ¶
Index ¶
- func NewMongoDB(ctx context.Context, config Config) (*mongo.Client, error)
- type Category
- func (c *Category) Add(ctx context.Context, telegramChatID int64, name string) error
- func (c *Category) AddToBeRenamedToCategory(ctx context.Context, telegramChatID int64, name string) error
- func (c *Category) List(ctx context.Context, telegramChatID int64) ([]core.Category, error)
- func (c *Category) Remove(ctx context.Context, telegramChatID int64, name string) error
- func (c *Category) Rename(ctx context.Context, telegramChatID int64, newName string) error
- type Config
- type Interaction
- type Note
- func (n *Note) Add(ctx context.Context, telegramChatID int64, categoryName, content string) error
- func (n *Note) ListInCategory(ctx context.Context, telegramChatID int64, categoryName string) ([]core.Note, error)
- func (n *Note) Remove(ctx context.Context, telegramChatID int64, categoryName, content string) error
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Category ¶
type Category struct {
// contains filtered or unexported fields
}
func NewCategory ¶
func NewCategory(collection *mongo.Collection) *Category
func (*Category) AddToBeRenamedToCategory ¶
type Interaction ¶
type Interaction struct {
// contains filtered or unexported fields
}
func NewInteraction ¶
func NewInteraction(collection *mongo.Collection) *Interaction
type Note ¶
type Note struct {
// contains filtered or unexported fields
}
func NewNote ¶
func NewNote(collection *mongo.Collection) *Note
func (*Note) ListInCategory ¶
type User ¶
type User struct {
// contains filtered or unexported fields
}
func NewUser ¶
func NewUser(collection *mongo.Collection) *User
func (*User) CheckChatIDExists ¶
Click to show internal directories.
Click to hide internal directories.