message

package
v0.1.0-alpha-6 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Message

type Message struct {
	*model.TopicEthSignatureMessage
}

Message serves as a model between Topic Message Watcher and Handler

func FromBytes

func FromBytes(data []byte) (*Message, error)

FromBytes instantiates new TopicMessage protobuf used internally by the Watchers/Handlers

func FromBytesWithTS

func FromBytesWithTS(data []byte, ts int64) (*Message, error)

FromBytesWithTS instantiates new TopicMessage protobuf used internally by the Watchers/Handlers

func FromString

func FromString(data, ts string) (*Message, error)

FromString instantiates new Topic Message protobuf from string `content` and `timestamp`

func NewSignature

func NewSignature(sourceChainId, targetChainId uint64, transferID, asset, receiver, amount, signature string) *Message

NewSignature instantiates Signature Message struct ready for submission to the Bridge Topic

func (*Message) ToBytes

func (tm *Message) ToBytes() ([]byte, error)

ToBytes marshals the underlying protobuf Message into bytes

Jump to

Keyboard shortcuts

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