converter

package
v0.29.0 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestDataConverter

func NewTestDataConverter() converter.DataConverter

NewTestDataConverter created new instance of TestDataConverter.

Types

type TestDataConverter

type TestDataConverter struct{}

TestDataConverter implements DataConverter using gob.

func (*TestDataConverter) FromPayload

func (dc *TestDataConverter) FromPayload(payload *commonpb.Payload, valuePtr interface{}) error

FromPayload converts single value from payload.

func (*TestDataConverter) FromPayloads

func (dc *TestDataConverter) FromPayloads(payloads *commonpb.Payloads, valuePtrs ...interface{}) error

FromPayloads converts to a list of values of different types.

func (*TestDataConverter) ToPayload

func (dc *TestDataConverter) ToPayload(value interface{}) (*commonpb.Payload, error)

ToPayload converts single value to payload.

func (*TestDataConverter) ToPayloads

func (dc *TestDataConverter) ToPayloads(values ...interface{}) (*commonpb.Payloads, error)

ToPayloads converts a list of values.

func (*TestDataConverter) ToString

func (dc *TestDataConverter) ToString(payload *commonpb.Payload) string

ToString converts payload object into human readable string.

func (*TestDataConverter) ToStrings

func (dc *TestDataConverter) ToStrings(payloads *commonpb.Payloads) []string

ToStrings converts payloads object into human readable strings.

Jump to

Keyboard shortcuts

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