Discover Packages
github.com/cloudevents/sdk-go/v2
event
datacodec
json
package
Version:
v2.5.0
Opens a new window with list of versions in this module.
Published: Aug 13, 2021
License: Apache-2.0
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 4
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package json holds the encoder/decoder implementation for `application/json`.
Decode takes `in` as []byte.
If Event sent the payload as base64, Decoder assumes that `in` is the
decoded base64 byte array.
Encode attempts to json.Marshal `in` into bytes. Encode will inspect `in`
and returns `in` unmodified if it is detected that `in` is already a []byte;
Or json.Marshal errors.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.