Category: File

java tutorials

How to Calculate Folder Size in Java

Calculating the size of a folder or directory is trivial. In Java you can recursively traverse each folder and calculate the size of each file individually, and return the sum of all the files....
java tutorials

How to Create a File in Java

This tutorial shows you how to create a file using java. First we explore the old way using the File class. Next we explore the new Path class introduced in Java 7. Create a...