DefaultPureeLogSerializer

Default Android implementation of the PureeLogSerializer interface.

This class provides a standard serialization mechanism for Android using Kotlin's serialization library. It converts PureeLog objects into JSON format by utilizing the kotlinx.serialization framework, which requires that log classes are annotated with @Serializable.

The serialization process uses the platform class information to obtain the appropriate serializer for each log type, ensuring type-safe serialization.

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open override fun <T : PureeLog> serialize(log: T, platformClass: PlatformClass<T>): JsonObject

Serializes a log object into JSON format using Kotlin's serialization library.