Package com.atlassian.bamboo.specs.util
Class FileUtils
- java.lang.Object
-
- com.atlassian.bamboo.specs.util.FileUtils
-
public final class FileUtils extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.StringreadFileContent(@NotNull java.nio.file.Path path, java.lang.String fileIsNullErrorMessage, java.lang.String fileReadErrorMessage)Read file content.static java.lang.StringreadFileToString(java.nio.file.Path path)
-
-
-
Method Detail
-
readFileContent
public static java.lang.String readFileContent(@NotNull @NotNull java.nio.file.Path path, java.lang.String fileIsNullErrorMessage, java.lang.String fileReadErrorMessage)Read file content.- Parameters:
path- to filefileIsNullErrorMessage- error message thrown when file is nullfileReadErrorMessage- error message thrown when can't read file- Returns:
- file body
-
readFileToString
public static java.lang.String readFileToString(java.nio.file.Path path) throws java.io.IOException- Throws:
java.io.IOException
-
-