Documentation ¶
Overview ¶
Implements gomobile bindings for go-waku. Contains a set of functions that are exported when go-waku is exported as libraries for mobile devices
Index ¶
- func AddPeer(address string, protocolID string) string
- func Connect(address string, ms int) string
- func ConnectPeerID(peerID string, ms int) string
- func ContentTopic(applicationName string, applicationVersion int, contentTopicName string, ...) string
- func DecodeAsymmetric(messageJSON string, privateKey string) string
- func DecodeSymmetric(messageJSON string, symmetricKey string) string
- func DefaultPubsubTopic() string
- func Disconnect(peerID string) string
- func FilterSubscribe(filterJSON string, peerID string, ms int) string
- func FilterUnsubscribe(filterJSON string, ms int) string
- func IsStarted() string
- func LightpushPublish(messageJSON string, topic string, peerID string, ms int) string
- func LightpushPublishEncodeAsymmetric(messageJSON string, topic string, peerID string, publicKey string, ...) string
- func LightpushPublishEncodeSymmetric(messageJSON string, topic string, peerID string, symmetricKey string, ...) string
- func ListenAddresses() string
- func NewNode(configJSON string) string
- func PeerCnt() string
- func PeerID() string
- func Peers() string
- func PubsubTopic(name string, encoding string) string
- func RelayEnoughPeers(topic string) string
- func RelayPublish(messageJSON string, topic string, ms int) string
- func RelayPublishEncodeAsymmetric(messageJSON string, topic string, publicKey string, optionalSigningKey string, ...) string
- func RelayPublishEncodeSymmetric(messageJSON string, topic string, symmetricKey string, ...) string
- func RelaySubscribe(topic string) string
- func RelayUnsubscribe(topic string) string
- func SetEventCallback(cb unsafe.Pointer)
- func SetMobileSignalHandler(handler SignalHandler)
- func Start() string
- func Stop() string
- func StoreQuery(queryJSON string, peerID string, ms int) string
- type FilterArgument
- type MobileSignalHandler
- type SignalHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConnectPeerID ¶
func ContentTopic ¶
func DecodeAsymmetric ¶
func DecodeSymmetric ¶
func DefaultPubsubTopic ¶
func DefaultPubsubTopic() string
func Disconnect ¶
func FilterSubscribe ¶ added in v0.2.0
func FilterUnsubscribe ¶ added in v0.2.0
func LightpushPublish ¶
func ListenAddresses ¶
func ListenAddresses() string
func PubsubTopic ¶
func RelayEnoughPeers ¶
func RelaySubscribe ¶
func RelayUnsubscribe ¶
func SetEventCallback ¶
func SetMobileSignalHandler ¶
func SetMobileSignalHandler(handler SignalHandler)
SetMobileSignalHandler setup geth callback to notify about new signal used for gomobile builds nolint
Types ¶
type FilterArgument ¶ added in v0.2.0
type FilterArgument struct { Topic string `json:"pubsubTopic,omitempty"` ContentFilters []pb.ContentFilter `json:"contentFilters,omitempty"` }
type MobileSignalHandler ¶
type MobileSignalHandler func([]byte)
SignalHandler is a simple callback function that gets called when any signal is received
type SignalHandler ¶
type SignalHandler interface {
HandleSignal(string)
}
SignalHandler defines a minimal interface a signal handler needs to implement. nolint
Click to show internal directories.
Click to hide internal directories.