embedded

package
Version: v2.0.0-...-a70d572 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const PluginEmbedded = "embedded"

Variables

This section is empty.

Functions

func NewClient

func NewClient(config cmap.CustomMap) (busType.Plugin, error)

NewClient func

func PrintDebug

func PrintDebug(message string, fields ...zapcore.Field)

PrintDebug log

func PrintError

func PrintError(message string, fields ...zapcore.Field)

PrintError log

func PrintInfo

func PrintInfo(message string, fields ...zapcore.Field)

PrintInfo log

func PrintWarn

func PrintWarn(message string, fields ...zapcore.Field)

PrintWarn log

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client struct

func (*Client) Close

func (c *Client) Close() error

Close implementation

func (*Client) Name

func (c *Client) Name() string

func (*Client) Publish

func (c *Client) Publish(topic string, data interface{}) error

Publish a data to a topic

func (*Client) Subscribe

func (c *Client) Subscribe(topic string, handler busType.CallBackFunc) (int64, error)

Subscribe a topic

func (*Client) Unsubscribe

func (c *Client) Unsubscribe(topic string, subscriptionID int64) error

Unsubscribe a topic

func (*Client) UnsubscribeAll

func (c *Client) UnsubscribeAll(topic string) error

UnsubscribeAll topics

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL