json

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventCodec

type EventCodec struct{}

EventCodec is a codec for marshaling and unmarshaling events to and from bytes in JSON format.

func (*EventCodec) MarshalEvent

func (c *EventCodec) MarshalEvent(ctx context.Context, event eh.Event) ([]byte, error)

MarshalEvent marshals an event into bytes in JSON format.

func (*EventCodec) UnmarshalEvent

func (c *EventCodec) UnmarshalEvent(ctx context.Context, b []byte) (eh.Event, context.Context, error)

UnmarshalEvent unmarshals an event from bytes in JSON format.

Jump to

Keyboard shortcuts

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