Creates an instance of Tyson.
This method deserializes the specified JSON into an object|array of the specified type.
the JSON object|array used during deserialization
a class|array of T
an object|array of type T. Returns undefined if json or type are undefined.
Returns the type adapter for the specified typeToken. This method uses a cache to avoid re-creating a new adapter for a previously requested TypeToken.
a TypeAdapter of T
This method serializes the specified object, into its equivalent JSON representation.
the object|array for which JSON representation is to be created
the specific type of src (required for arrays)
JSON representation of src
Generated using TypeDoc
This is the main class. Tyson is typically used by first constructing a Tyson instance and then invoking toJson or fromJson methods on it.
Here is an example:
Tyson