| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| private static UncheckedIOException | |
| private static UncheckedIOException | |
| private static UncheckedIOException | |
| private static void | |
| public static String | |
| public static String | |
| private static File | |
| public static File | |
| public static void | |
| public static List | Returns: the names of the files inside the specified directory.the name of the directory to start the search from. dirName, boolean if recurse)true, we will look in subdirectories.Returns the names of the files inside the specified directory. |
| private static List | Returns: the names of the files inside the specified directory.the name of the directory to start the search from. dir, boolean if recurse)true, we will look in subdirectories.Returns the names of the files inside the specified directory. |
| public static Optional | |
| public static List | |
| public static List | |
| public static File | |
| public static File | |
| public static File | |
| public static File | Returns: the created file.Creates a new directory in the system's temporary directory. |
| public static File | Returns: the system's temporary directory.
Deprecated
Use either
Returns the system's temporary directory.
org. or org.
|
| public static String | Returns: the path of the system's temporary directory.Returns the path of the system's temporary directory. |
| Files | back to summary |
|---|---|
| private Files() | |
| cannotCreateNewFile | back to summary |
|---|---|
| private static UncheckedIOException cannotCreateNewFile(String path, String reason) | |
| cannotCreateNewFile | back to summary |
|---|---|
| private static UncheckedIOException cannotCreateNewFile(String path, Exception cause) | |
| cannotCreateNewFile | back to summary |
|---|---|
| private static UncheckedIOException cannotCreateNewFile(String path, String reason, Exception cause) | |
| checkArgumentCharsetIsSupported | back to summary |
|---|---|
| private static void checkArgumentCharsetIsSupported(String charsetName) | |
| contentOf | back to summary |
|---|---|
| public static String contentOf(File file, String charsetName) Loads the text content of a file into a character string.
| |
| contentOf | back to summary |
|---|---|
| public static String contentOf(File file, Charset charset) Loads the text content of a file into a character string.
| |
| createFileIfPathIsNotANonEmptyDirectory | back to summary |
|---|---|
| private static File createFileIfPathIsNotANonEmptyDirectory(String path) | |
| currentFolder | back to summary |
|---|---|
| public static File currentFolder() Returns the current directory.
| |
| delete | back to summary |
|---|---|
| public static void delete(File file)
Deprecated use https://commons.apache.org/proper/commons-io/javadocs/api-release/org/apache/commons/io/FileUtils.html#forceDelete-java.io.File- instead Deletes the given file or directory.
| |
| fileNamesIn | back to summary |
|---|---|
| public static List Returns the names of the files inside the specified directory.
| |
| fileNamesIn | back to summary |
|---|---|
| private static List Returns the names of the files inside the specified directory. | |
| getFileNameExtension | back to summary |
|---|---|
| public static Optional | |
| linesOf | back to summary |
|---|---|
| public static List Loads the text content of a file into a list of strings, each string corresponding to a line. The line endings are either \n, \r or \r\n.
| |
| linesOf | back to summary |
|---|---|
| public static List Loads the text content of a file into a list of strings, each string corresponding to a line. The line endings are either \n, \r or \r\n.
| |
| newFile | back to summary |
|---|---|
| public static File newFile(String path) Creates a new file using the given path.
| |
| newFolder | back to summary |
|---|---|
| public static File newFolder(String path) Creates a new directory using the given path.
| |
| newTemporaryFile | back to summary |
|---|---|
| public static File newTemporaryFile() Creates a new file in the system's temporary directory. The name of the file will be the result of:
| |
| newTemporaryFolder | back to summary |
|---|---|
| public static File newTemporaryFolder() Creates a new directory in the system's temporary directory. The name of the directory will be the result of:
| |
| temporaryFolder | back to summary |
|---|---|
| public static File temporaryFolder()
Deprecated Use either Returns the system's temporary directory.
| |
| temporaryFolderPath | back to summary |
|---|---|
| public static String temporaryFolderPath() Returns the path of the system's temporary directory. This method appends the system's file separator at the end of the path.
| |