Documentation ¶
Index ¶
- func DoLogin(username, password, homeserverURL, userID, accessToken string, ...)
- func GetClient(homeserverURL, userID, accessToken string) (client *gomatrix.Client, err error)
- func GetOwnUserAvatar(cli *gomatrix.Client) (avatar *gui.QPixmap, err error)
- func GetUserAvatar(cli *gomatrix.Client, mxid string, size int) (avatarResp *gui.QPixmap, err error)
- func LoginUser(username, password string) (*gomatrix.Client, error)
- type HTMLMessage
- type JoinedRooms
- type Room
- type RoomAliases
- type RoomAvatar
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DoLogin ¶
func DoLogin(username, password, homeserverURL, userID, accessToken string, results chan<- *gomatrix.Client, wg *sync.WaitGroup)
DoLogin generates the needed Client
func GetOwnUserAvatar ¶
GetOwnUserAvatar returns a *gui.QPixmap of an UserAvatar
Types ¶
type HTMLMessage ¶
type HTMLMessage struct { MsgType string `json:"msgtype,omitempty"` Body string `json:"body,omitempty"` FormattedBody string `json:"formatted_body,omitempty"` Format string `json:"format,omitempty"` }
HTMLMessage is the contents of a Matrix formated message event.
type JoinedRooms ¶
type JoinedRooms struct {
JoinedRooms []string `json:"joined_rooms,omitempty"`
}
JoinedRooms is the json response when getting the joined rooms list
type Room ¶
type Room struct { RoomID string RoomName string RoomAvatarURL string RoomTopic string // contains filtered or unexported fields }
Room saves the information of a Room
func (*Room) GetRoomAvatar ¶
GetRoomAvatar generates the Avatar Image for a Room
func (*Room) GetRoomName ¶
GetRoomName gives you the name of the current Room
func (*Room) GetRoomTopic ¶
GetRoomTopic returns the Topic of the Room and crawls it if needed
type RoomAliases ¶
type RoomAliases struct { Age int `json:"age,omitempty"` Content struct { Aliases []string `json:"aliases,omitempty"` } `json:"content,omitempty"` EventID string `json:"event_id,omitempty"` OriginServerTs int64 `json:"origin_server_ts,omitempty"` RoomID string `json:"room_id,omitempty"` Sender string `json:"sender,omitempty"` StateKey string `json:"state_key,omitempty"` Type string `json:"type,omitempty"` }
RoomAliases is the json response when getting the room aliases
type RoomAvatar ¶
type RoomAvatar struct { Age int `json:"age,omitempty"` Content struct { Info struct { H int `json:"h,omitempty"` Mimetype string `json:"mimetype,omitempty"` Size int `json:"size,omitempty"` W int `json:"w,omitempty"` } `json:"info,omitempty"` URL string `json:"url,omitempty"` } `json:"content,omitempty"` EventID string `json:"event_id,omitempty"` OriginServerTs int64 `json:"origin_server_ts,omitempty"` RoomID string `json:"room_id,omitempty"` Sender string `json:"sender,omitempty"` StateKey string `json:"state_key,omitempty"` Type string `json:"type,omitempty"` }
RoomAvatar is the json response when getting the room avatar list
Click to show internal directories.
Click to hide internal directories.