Documentation
¶
Index ¶
- type Channel
- type Connection
- func (c *Connection) Close() error
- func (c *Connection) Connect(ctx context.Context, host net.IP, port int) error
- func (c *Connection) NewChannel(sourceId, destinationId, namespace string) *Channel
- func (c *Connection) ReceiveLoop()
- func (c *Connection) Send(payload interface{}, sourceId, destinationId, namespace string) error
- type Payload
- type PayloadHeaders
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Channel ¶
type Channel struct { DestinationId string // contains filtered or unexported fields }
func NewChannel ¶
func NewChannel(conn *Connection, sourceId, destinationId, namespace string) *Channel
func (*Channel) Message ¶
func (c *Channel) Message(message *api.CastMessage, headers *PayloadHeaders)
func (*Channel) OnMessage ¶
func (c *Channel) OnMessage(responseType string, cb func(*api.CastMessage))
type Connection ¶
type Connection struct {
// contains filtered or unexported fields
}
func NewConnection ¶
func NewConnection() *Connection
func (*Connection) Close ¶
func (c *Connection) Close() error
func (*Connection) NewChannel ¶
func (c *Connection) NewChannel(sourceId, destinationId, namespace string) *Channel
func (*Connection) ReceiveLoop ¶
func (c *Connection) ReceiveLoop()
func (*Connection) Send ¶
func (c *Connection) Send(payload interface{}, sourceId, destinationId, namespace string) error
type PayloadHeaders ¶
Click to show internal directories.
Click to hide internal directories.