protobuf_helper

package
v1.3.0-alpha.9 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyExtra added in v1.1.23

func CopyExtra(x *string) map[string]string

func CopyString added in v1.1.23

func CopyString(x *string) string

func ExtractStringMap

func ExtractStringMap(xs map[string]*wrappers.StringValue) map[string]interface{}

func ExtractStringMapToString

func ExtractStringMapToString(xs map[string]*wrappers.StringValue) map[string]string

func FromTime

func FromTime(t time.Time) timestamp.Timestamp

func FromTimestamp

func FromTimestamp(ts int64) timestamp.Timestamp

func MustParseExtra added in v1.1.23

func MustParseExtra(x map[string]*wrappers.StringValue) string

func Now

func Now() timestamp.Timestamp

func ToStringMap added in v1.1.26

func ToStringMap(msg proto.Message) map[string]interface{}

func ToTime

func ToTime(t *timestamp.Timestamp) time.Time

Types

type Enumer

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

func NewEnumer

func NewEnumer(prefix string, names map[int32]string, values map[string]int32) Enumer

func (Enumer) ToString

func (self Enumer) ToString(x int32) string

func (Enumer) ToValue

func (self Enumer) ToValue(x string) int32

Jump to

Keyboard shortcuts

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