https://kotlinlang.org logo
#announcements
Title
# announcements
p

pniederw

07/12/2017, 3:00 AM
Constantly torn between
java.io.File
+ Kotlin extensions and
java.nio.file.Path/Files
without. Wish I wouldn’t need to make a choice between better API usability and better file system implementation.
i

ilya.gorbunov

07/12/2017, 12:31 PM
Which extensions on
Path
do you miss the most?
p

pniederw

07/24/2017, 4:22 AM
@ilya.gorbunov Hard to say.
java.nio.file.Path/Files
is just much less convenient to use than java.io.File + Kotlin extensions/APIs. Filed: https://youtrack.jetbrains.com/issue/KT-19192
Part of it is extension methods vs. static methods, but that’s not the whole story.
Another example is that Kotlin extension methods create missing target dirs automatically.
Also
readText
and
writeText
, and others.