Module serenity::json

source ·
Expand description

This module exports different types for JSON interactions. It encapsulates the differences between serde_json and simd-json to allow ignoring those in the rest of the codebase.

Macros§

  • Construct a serde_json::Value from a JSON literal.

Structs§

  • This type represents all possible errors that can occur when serializing or deserializing JSON data.

Constants§

Functions§

  • Deserialize an instance of type T from bytes of JSON text.
  • Deserialize an instance of type T from bytes of JSON text.
  • Deserialize an instance of type T from a string of JSON text.
  • Interpret a Value as an instance of type T.
  • Converts a HashMap into a final JsonMap representation.
  • Serialize the given data structure as a String of JSON.
  • Serialize the given data structure as a pretty-printed String of JSON.
  • Convert a T into a Value which is an enum that can represent any valid JSON data.
  • Serialize the given data structure as a JSON byte vector.
  • Serialize the given data structure as a pretty-printed JSON byte vector.

Type Aliases§