toDataMap

fun <T : Any> T.toDataMap(vararg excludeKeys: String): Map<String, Any?>

Converts a data class object to a map, where keys are mapped property names and values are the property values.

Only primary constructor properties are included, under the same mapped names toDataObject reads.

Return

A map of mapped property name to property value.

Parameters

excludeKeys

Mapped key names to exclude from the resulting map.