model

package
v0.0.0-...-4cd1d87 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 6, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Message

type Message struct {
	ID                MessageID
	User              User
	Text              MessageText
	ReferencedMessage *Message
	MediaNum          int
	ReplyUserID       UserID
}

func (*Message) GetIDStr

func (m *Message) GetIDStr() string

func (*Message) HasKeyWord

func (m *Message) HasKeyWord(keyword string) bool

func (*Message) HasMessageReference

func (m *Message) HasMessageReference() bool

func (*Message) IsDebugMode

func (m *Message) IsDebugMode() bool

func (*Message) IsRepliedTo

func (m *Message) IsRepliedTo(user *User) bool

type MessageEvent

type MessageEvent struct {
	TargetUserID UserID
	IsShared     bool
	Message      *Message
}

type MessageID

type MessageID int64

func (MessageID) ToString

func (m MessageID) ToString() string

type MessageText

type MessageText string

func (MessageText) HasKeyword

func (m MessageText) HasKeyword(keyword string) bool

type User

type User struct {
	ID   UserID
	Name UserName
}

func NewTwitterUser

func NewTwitterUser(id int64, name string) User

func (*User) GetIDStr

func (u *User) GetIDStr() string

func (*User) IsOwnMessage

func (u *User) IsOwnMessage(message *Message) bool

type UserID

type UserID int64

type UserName

type UserName string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL