Package io.github.dornol.excelkit.core
Class TempResourceCreator
java.lang.Object
io.github.dornol.excelkit.core.TempResourceCreator
Utility class for creating temporary files and directories with appropriate permissions.
- Since:
- 2025-07-19
-
Method Details
-
createTempDirectory
Creates a new temporary directory.On POSIX-compliant file systems, the directory is created with restricted (rwx------) permissions. On Windows (ACL-based), the directory's ACL is restricted to the current user only.
- Returns:
- Path to the created temporary directory
- Throws:
TempResourceCreateException- If directory creation fails
-
createTempFile
Creates a new temporary file in the specified directory.- Parameters:
directory- The parent directoryprefix- The file prefixsuffix- The file suffix (extension)- Returns:
- Path to the created temporary file
- Throws:
TempResourceCreateException- If file creation fails
-