Documentation ¶
Index ¶
Constants ¶
View Source
const EqualSignReplacer = "(^.!#*]"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ByTimestamp ¶
type ByTimestamp []*Message
func (ByTimestamp) Len ¶
func (m ByTimestamp) Len() int
func (ByTimestamp) Less ¶
func (m ByTimestamp) Less(i, j int) bool
func (ByTimestamp) Swap ¶
func (m ByTimestamp) Swap(i, j int)
type Message ¶
type Message struct { ID string `bson:"_id"` Timestamp time.Time `bson:"timestamp" json:"timestamp"` Type MessageType `json:"type" bson:"type"` MessageID string `json:"message_id" bson:"message_id"` UserID string `json:"user_id" bson:"user_id"` Username string `json:"username" bson:"username"` GroupID string `json:"group_id" bson:"group_id"` Text string `json:"text" bson:"text"` ExpirationDate time.Time `json:"expiration_date" bson:"expiration_date"` }
type MessageType ¶
type MessageType string
const ( MessageTypeUser MessageType = "user" MessageTypeGroup MessageType = "group" )
type Schedule ¶
type Schedule struct { Id bson.ObjectId `json:"_" bson:"_id"` Name string `json:"name" bson:"name"` Cron string `json:"cron" bson:"cron"` Message string `json:"message" bson:"message"` ReplyTo string `json:"reply_to" bson:"reply_to"` IsDone bool `json:"is_done" bson:"is_done"` CreatedAt time.Time `json:"created_at" bson:"created_at"` LastRun time.Time `json:"last_run" bson:"last_run"` }
func (*Schedule) ShortString ¶
Click to show internal directories.
Click to hide internal directories.