
commonMain.Preconditions.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of chart-js Show documentation
Show all versions of chart-js Show documentation
A collection of drawing/charting utilities
package com.juul.krayon.chart
internal fun checkRectangular(listOfLists: List>) {
if (listOfLists.isEmpty()) return
val expectedLength = listOfLists.first().size
for (index in 1 until listOfLists.size) {
val innerListLength = listOfLists[index].size
check(innerListLength == expectedLength) {
"List is not rectangular. Found inner list at index $index with length $innerListLength, but previous lists had length $expectedLength."
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy