1. Overview
In this tutorial, We'll be learning how to create a file in java and how to create a temp file in java.
Example programs demonstrated in the following methods.
createNewFile() createTempFile()
Example Programs on Files
createNewFile() method is used to create a new empty file.
createTempFile() method is used to create a temporary file.
createNewFile() method is used to create a new empty file.
createTempFile() method is used to create a temporary file.