Skip to content

Commit

Permalink
Rename all remaining MapColumn to ColumnGroup
Browse files Browse the repository at this point in the history
  • Loading branch information
koperagen committed Aug 22, 2022
1 parent 97c1beb commit 9713fa2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ internal fun <A, B> DataFrame<A>.joinImpl(

require(leftJoinColumns.size == rightJoinColumns.size)

// replace all MapColumns in join with nested columns, matching by column path
// replace all ColumnGroups in join with nested columns, matching by column path
val allLeftJoinColumns = mutableListOf<ColumnWithPath<*>>()
val allRightJoinColumns = mutableListOf<ColumnWithPath<*>>()

Expand Down Expand Up @@ -220,7 +220,7 @@ internal fun <A, B> DataFrame<A>.joinImpl(
val newColumn = when (srcColumn.kind) {
ColumnKind.Value -> DataColumn.createValueColumn(srcColumn.name, columnValues.asList(), srcColumn.type.withNullability(hasNulls))
ColumnKind.Frame -> DataColumn.createFrameColumn(srcColumn.name, columnValues.asList() as List<AnyFrame>)
ColumnKind.Group -> error("Unexpected MapColumn at path ${srcColumn.path}")
ColumnKind.Group -> error("Unexpected ColumnGroup at path ${srcColumn.path}")
}
srcColumn.path to newColumn
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ internal fun <T> DataColumn<T>.updateWith(values: List<T>): DataColumn<T> = when
null -> null
is List<*> -> it[colIndex]
is AnyRow -> it.getOrNull(col.name)
else -> require(false) { "Can not add value '$it' to MapColumn" }
else -> require(false) { "Can not add value '$it' to ColumnGroup" }
}
}
col.updateWith(newValues)
Expand Down

0 comments on commit 9713fa2

Please sign in to comment.