Learn how to use the built-in method exposed by the File class or use the Files class from the Java NIO package to rename files in Kotlin
Also find me here:
Baeldung Author
Jacek Polom
I'm a software developer with more than ten years of experience. On daily basis working with Java and Kotlin. Focused on quality from many perspectives.
Here's what I've written (so far):
Baeldung on Kotlin
- All
- Kotlin Collections (5)
- Kotlin Strings (4)
- Kotlin IO (3)
- Kotlin Classes and Objects (3)
- Kotlin Basics (1)
- Algorithms (1)
Convert String Array to Int Array in Kotlin
Filed under Kotlin Strings
Learn to convert a String array to an Int array in Kotlin and how to handle potential exceptions.
Convert Any to Int in Kotlin
Filed under Kotlin Classes and Objects
Learn various ways to convert a variable of type Any to an Int and understand why this requires careful consideration of the data at hand.
Remove Elements From a List While Iterating in Kotlin
Filed under Kotlin Basics
Learn how to remove elements from a list when iterating over it.
Fibonacci Series in Kotlin
Filed under Algorithms
Learn a few techniques to generate the Fibonacci series of numbers in Kotlin.
Check if Condition Is True for All Elements in a List
Filed under Kotlin Collections
Learn how to check if a condition is true for all elements in a Kotlin list.
Sort LinkedHashMap by Values in Kotlin
Filed under Kotlin Collections
Learn how to sort a LinkedHashMap based on its values.
How to Work With List Casts in Kotlin
Filed under Kotlin Collections
Learn how to handle list type checking.
Read and Write to Excel With Kotlin
Filed under Kotlin IO
Learn how to use the Apache POI library to read and write Excel files.
Extend Data Class in Kotlin
Filed under Kotlin Classes and Objects
Learn how to extend a data class in Kotlin.
Kotlin Equivalent to Java String Arrays
Filed under Kotlin Collections, Kotlin Strings
Learn how to create an array of primitives and ordinary types.
How to Invoke External Command From Within Kotlin
Filed under Kotlin IO
Learn how to invoke external commands from Kotlin.
Parsing a URL String
Filed under Kotlin Strings
Learn how to parse an URL string with URL and URI classes.
Companion Objects in Kotlin Interfaces
Filed under Kotlin Classes and Objects
Learn how to define a companion object in an interface.
Creating a Byte Array in Kotlin
Filed under Kotlin Collections
Learn how to create a byte array in Kotlin
Convert a String to a Byte Array in Kotlin
Filed under Kotlin Strings
Learn how to convert a String to a byte array in Kotlin.