public final class CommonFiles
extends java.lang.Object
| Constructor and Description |
|---|
CommonFiles() |
| Modifier and Type | Method and Description |
|---|---|
static java.nio.file.Path |
createCommonAppFile(java.nio.file.Path path)
Creates a file, using the relative path provided, in the system-appropriate directory
for persistent, cross-process, cross-user data.
|
public static java.nio.file.Path createCommonAppFile(java.nio.file.Path path)
throws java.io.IOException
On Windows machines, the Windows directory assigned to the CommonApplicationData
special folder is used. On *NIX machines, /var/tmp (not java.io.tmpdir)
is used.
path - the relative path to the file to create within the common directoryjava.io.FileNotFoundException - if the system-appropriate directory does not existjava.io.IOException - if an error is raised while attempting to create the filejava.lang.IllegalArgumentException - if path is not relative or is emptyCopyright © 2022. All rights reserved.