Documentation
¶
Index ¶
- Variables
- func MarshalProtobuf(v MarshallerProtobuf) (bs []byte)
- func MarshalTypedProtobuf(v MarshallerTypedProtobuf) (bs []byte)
- func NewSliceProtobuf[T any](elemProtobuf mus.Serializer[T]) sliceProtobuf[T]
- func NewValidSliceProtobuf[T any](elemProtobuf mus.Serializer[T], ops ...slops.SetOption[T]) validSliceProtobuf[T]
- func NewValidStringProtobuf(ops ...strops.SetOption) mus.Serializer[string]
- func NewValidStringUnsafeProtobuf(ops ...strops.SetOption) mus.Serializer[string]
- type MarshallerProtobuf
- type MarshallerTypedProtobuf
- type Timestamp
Constants ¶
This section is empty.
Variables ¶
View Source
var ( LenSer = lenSer{} String = ord.NewStringSer(strops.WithLenSer(LenSer)) StringUnsafe = unsafe.NewStringSer(strops.WithLenSer(LenSer)) )
View Source
var TimestampNativeProtobuf = timestampNativeProtobuf{}
View Source
var TimestampProtobuf = timestampProtobuf{}
Functions ¶
func MarshalProtobuf ¶
func MarshalProtobuf(v MarshallerProtobuf) (bs []byte)
MarshalProtobuf creates and returns a byte slice filled with the serialized data.
func MarshalTypedProtobuf ¶
func MarshalTypedProtobuf(v MarshallerTypedProtobuf) (bs []byte)
MarshalTypedProtobuf creates and returns a byte slice filled with the serialized data.
func NewSliceProtobuf ¶
func NewSliceProtobuf[T any](elemProtobuf mus.Serializer[T]) sliceProtobuf[T]
NewSliceSer returns a new slice serializer with the given element serializer.
func NewValidSliceProtobuf ¶
func NewValidSliceProtobuf[T any](elemProtobuf mus.Serializer[T], ops ...slops.SetOption[T]) validSliceProtobuf[T]
NewValidSliceSer returns a new valid slice serializer.
func NewValidStringProtobuf ¶
NewValidStringProtobuf returns a new valid string serializer.
func NewValidStringUnsafeProtobuf ¶
NewValidStringUnsafeProtobuf returns a new valid string serializer.
Types ¶
type MarshallerProtobuf ¶
MarshallerProtobuf interface wraps MarhsalProtobuf and SizeProtobuf methods.
type MarshallerTypedProtobuf ¶
type MarshallerTypedProtobuf interface { MarshalTypedProtobuf(bs []byte) (n int) SizeTypedProtobuf() (size int) }
MarshallerProtobuf interface wraps the MarshalProtobuf and SizeProtobuf methods. It is intended for use with DTS.
Click to show internal directories.
Click to hide internal directories.