Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRPCServer ¶
func NewRPCServer(dispatch chan MessageArgs, host, port string)
Types ¶
type Message ¶
type Message struct {
// contains filtered or unexported fields
}
func (*Message) Dispatch ¶
func (m *Message) Dispatch(args *MessageArgs, reply *MessageReply) error
type MessageArgs ¶
type MessageArgs struct { ID int64 `json:"id"` From string `json:"from"` Content string `json:"content"` Time time.Time `json:"time"` Channel string `json:"channel"` Host string `json:"host"` }
func (MessageArgs) Key ¶
func (args MessageArgs) Key() string
func (MessageArgs) Message ¶
func (args MessageArgs) Message() models.Message
func (MessageArgs) String ¶
func (args MessageArgs) String() string
type MessageReply ¶
type MessageReply struct {
OK bool
}
Click to show internal directories.
Click to hide internal directories.