@@ -24,6 +24,7 @@ import org.jetbrains.kotlinx.dataframe.columns.ColumnReference
24
24
import org.jetbrains.kotlinx.dataframe.columns.toColumnSet
25
25
import org.jetbrains.kotlinx.dataframe.dataTypes.IFRAME
26
26
import org.jetbrains.kotlinx.dataframe.dataTypes.IMG
27
+ import org.jetbrains.kotlinx.dataframe.documentation.ExcludeFromSources
27
28
import org.jetbrains.kotlinx.dataframe.exceptions.CellConversionException
28
29
import org.jetbrains.kotlinx.dataframe.exceptions.TypeConversionException
29
30
import org.jetbrains.kotlinx.dataframe.impl.api.Parsers
@@ -189,27 +190,38 @@ public fun <T : Any> DataColumn<T?>.convertToDouble(): DataColumn<Double?> = con
189
190
* If [locale] parameter is defined, it's number format is used for parsing.
190
191
* If [locale] parameter is null, the current system locale is used.
191
192
* If the column cannot be parsed, then the POSIX format is used.
192
- *
193
+ */
194
+ @ExcludeFromSources
195
+ private interface DataColumnStringConvertToDoubleDoc
196
+
197
+ /* * @include [DataColumnStringConvertToDoubleDoc] */
198
+ @JvmName(" convertToDoubleFromString" )
199
+ public fun DataColumn<String>.convertToDouble (locale : Locale ? = null): DataColumn <Double > =
200
+ convertToDouble(locale = locale, useFastDoubleParser = false )
201
+
202
+ /* *
203
+ * @include [DataColumnStringConvertToDoubleDoc]
193
204
* @param useFastDoubleParser whether to use the new _experimental_ FastDoubleParser, defaults to `false` for now.
194
205
*/
195
206
@JvmName(" convertToDoubleFromString" )
196
207
public fun DataColumn<String>.convertToDouble (
197
208
locale : Locale ? = null,
198
- useFastDoubleParser : Boolean = false ,
209
+ useFastDoubleParser : Boolean ,
199
210
): DataColumn <Double > = this .castToNullable().convertToDouble(locale, useFastDoubleParser).castToNotNullable()
200
211
212
+ /* * @include [DataColumnStringConvertToDoubleDoc] */
213
+ @JvmName(" convertToDoubleFromStringNullable" )
214
+ public fun DataColumn<String?>.convertToDouble (locale : Locale ? = null): DataColumn <Double ?> =
215
+ convertToDouble(locale = locale, useFastDoubleParser = false )
216
+
201
217
/* *
202
- * Parses a String column to Double considering locale (number format).
203
- * If [locale] parameter is defined, it's number format is used for parsing.
204
- * If [locale] parameter is null, the current system locale is used.
205
- * If the column cannot be parsed, then the POSIX format is used.
206
- *
218
+ * @include [DataColumnStringConvertToDoubleDoc]
207
219
* @param useFastDoubleParser whether to use the new _experimental_ FastDoubleParser, defaults to `false` for now.
208
220
*/
209
221
@JvmName(" convertToDoubleFromStringNullable" )
210
222
public fun DataColumn<String?>.convertToDouble (
211
223
locale : Locale ? = null,
212
- useFastDoubleParser : Boolean = false ,
224
+ useFastDoubleParser : Boolean ,
213
225
): DataColumn <Double ?> {
214
226
fun applyParser (parser : (String ) -> Double? ): DataColumn <Double ?> {
215
227
var currentRow = 0
0 commit comments