Package io.helidon.webserver.testsupport
Class TemporaryFolder
- java.lang.Object
-
- io.helidon.webserver.testsupport.TemporaryFolder
-
public class TemporaryFolder extends Object
A helper class that represents a temporary folder.
-
-
Constructor Summary
Constructors Constructor Description TemporaryFolder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FilenewFile(String name)Create a new regular file inside the root folder.FilenewFolder(String name)Create a new directory inside the root folder.Fileroot()Return the root of the temporary folder.
-
-
-
Method Detail
-
newFile
public File newFile(String name) throws IOException
Create a new regular file inside the root folder.- Parameters:
name- the name of the file to create- Returns:
- the created
Fileinstance - Throws:
IOException- if an error occurred while create the fileIllegalStateException- if the file already exist
-
newFolder
public File newFolder(String name)
Create a new directory inside the root folder.- Parameters:
name- the name of the directory to create- Returns:
- the created
Fileinstance
-
-