Package-level declarations

Types

Link copied to clipboard
object FloatAsIntSerializer : <ERROR CLASS> ERROR CLASS: Symbol not found for KSerializer<kotlin/Int>

Replicates Jackson's ACCEPT_FLOAT_AS_INT behaviour for Int fields. A floating-point JSON number is truncated to Int by dropping the fractional part, exactly like Jackson's default truncation behaviour.

Link copied to clipboard
object FloatAsLongSerializer : <ERROR CLASS> ERROR CLASS: Symbol not found for KSerializer<kotlin/Long>

Replicates Jackson's ACCEPT_FLOAT_AS_INT behaviour for Long fields. A floating-point JSON number is truncated to Long by dropping the fractional part, exactly like Jackson's default truncation behaviour.

Link copied to clipboard
abstract class JsonTransformSerializer<T : Any>(tSerializer: ERROR CLASS: Symbol not found for KSerializer<T>, singleValueAsListKeys: Set<String> = emptySet(), emptyArrayAsNullKeys: Set<String> = emptySet(), emptyStringAsNullKeys: Set<String> = emptySet()) : <ERROR CLASS> ERROR CLASS: Symbol not found for JsonTransformingSerializer<T>

Composable deserialize transformer that applies multiple Jackson-equivalent behaviours to specific fields by key. Pass only the sets you need; all default to empty (no-op).

Link copied to clipboard
abstract class NonEmptySerializer<T : Any>(tSerializer: ERROR CLASS: Symbol not found for KSerializer<T>) : <ERROR CLASS> ERROR CLASS: Symbol not found for JsonTransformingSerializer<T>

Replicates Jackson's @JsonInclude(JsonInclude.Include.NON_EMPTY) behaviour. Strips null, empty strings, empty arrays, and empty objects from the serialized output. Requires the enclosing Json instance to have encodeDefaults = true, which is already in our default global Json instance.

Link copied to clipboard
object NullableStringSerializer : <ERROR CLASS> ERROR CLASS: Symbol not found for KSerializer<kotlin/String?>

Convenience serializer for nullable String fields that combines ACCEPT_EMPTY_STRING_AS_NULL_OBJECT with null passthrough. An empty JSON string ("") or JSON null is decoded as null.

Link copied to clipboard
abstract class WriteOnlySerializer<T : Any>(tSerializer: ERROR CLASS: Symbol not found for KSerializer<T>, keysToIgnore: Set<String>) : <ERROR CLASS> ERROR CLASS: Symbol not found for JsonTransformingSerializer<T>

Replicates Jackson's @JsonProperty(access = JsonProperty.Access.WRITE_ONLY) behaviour. Properties in keysToIgnore are deserialized normally but omitted from serialized output.