Skip to content

Nested Map -> DataRow conversion#1756

Draft
Jolanrensen wants to merge 1 commit intomasterfrom
nested-map-to-datarow
Draft

Nested Map -> DataRow conversion#1756
Jolanrensen wants to merge 1 commit intomasterfrom
nested-map-to-datarow

Conversation

@Jolanrensen
Copy link
Collaborator

Fixes #1755

created new overloads for Map<*, *>.toDataRow() expanded with maxDepth and convertKeysToString to allow recursive map -> datarow conversion with key -> string handling

@JvmOverloads is added to avoid bytecode incompatibility between versions.

TODO: Iterable<Map<*, *>>.toDataFrame()

…epth` and `convertKeysToString` to allow recursive map -> datarow conversion with key->string handling
@Jolanrensen
Copy link
Collaborator Author

@AndreiKingsley @koperagen
One important thing: what to do about lists/iterables inside the map? Should we convert those too? A Iterable<Map<String, *>> can be seen and converted to a DataFrame after all, making Iterable<String, List<Map<String, *>>> a DataFrame with FrameColumns.

Plus, Map<String, Iterable<*>>'s can also be converted to a DataFrame. Should that be done?

(Also where have I seen this before... oh right JSON objects/arrays -> DataFrame XD)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Map<String, Any?> to DataRow conversion with nested maps

1 participant