matterclient

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: May 24, 2016 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Credentials

type Credentials struct {
	Login  string
	Team   string
	Pass   string
	Server string
	NoTLS  bool
}

type MMClient

type MMClient struct {
	*Credentials
	Client       *model.Client
	WsClient     *websocket.Conn
	Channels     *model.ChannelList
	MoreChannels *model.ChannelList
	User         *model.User
	Users        map[string]*model.User
	MessageChan  chan *Message
	Team         *model.Team
	// contains filtered or unexported fields
}

func New

func New(login, pass, team, server string) *MMClient

func (*MMClient) GetChannelHeader

func (m *MMClient) GetChannelHeader(id string) string

func (*MMClient) GetChannelId

func (m *MMClient) GetChannelId(name string) string

func (*MMClient) GetChannelName

func (m *MMClient) GetChannelName(id string) string

func (*MMClient) GetPosts

func (m *MMClient) GetPosts(channelId string, limit int) *model.PostList

func (*MMClient) GetPostsSince

func (m *MMClient) GetPostsSince(channelId string, time int64) *model.PostList

func (*MMClient) JoinChannel

func (m *MMClient) JoinChannel(channel string) error

func (*MMClient) Login

func (m *MMClient) Login() error

func (*MMClient) PostMessage

func (m *MMClient) PostMessage(channel string, text string)

func (*MMClient) SearchPosts

func (m *MMClient) SearchPosts(query string) *model.PostList

func (*MMClient) SetLogLevel

func (m *MMClient) SetLogLevel(level string)

func (*MMClient) UpdateChannelHeader

func (m *MMClient) UpdateChannelHeader(channelId string, header string)

func (*MMClient) UpdateChannels

func (m *MMClient) UpdateChannels() error

func (*MMClient) UpdateLastViewed

func (m *MMClient) UpdateLastViewed(channelId string)

func (*MMClient) UpdateUsers

func (m *MMClient) UpdateUsers() error

func (*MMClient) UsernamesInChannel

func (m *MMClient) UsernamesInChannel(channelName string) []string

func (*MMClient) WsReceiver

func (m *MMClient) WsReceiver()

type Message

type Message struct {
	Raw      *model.Message
	Post     *model.Post
	Team     string
	Channel  string
	Username string
	Text     string
}

Jump to

Keyboard shortcuts

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