Contents
Class ClasUtilsFile
java.lang.Object
org.jlab.utils.system.ClasUtilsFile
- Author:
- gavalian
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String
createFileName
(String filename, String addition, boolean preservePath) returns a new file name which is composed of the file name given and then by adding given string to it. if flag preservePath is true, then file name will have the same path as the original file name.getFileList
(String directory) returns list of files in the directory. absolute path is given.getFileList
(String env, String rpath) returns list of files in the directory defined by environment variable and a relative path.getFileList
(String env, String rpath, String ext) returns a file list that contains files with given extensiongetFileNamesRelative
(List<String> files) Returs relative paths of file names from list of absolute paths.static String
getName()
static String
getResourceDir
(String env, String rpath) returns package resource directory with given enviromental variable and relative path.static void
static void
prints a log message with the module name included.Reads a text file into a list of stringsstatic String
readFileString
(String filename) Reads a text file into one string.static void
-
Constructor Details
-
Method Details
-
getName
-
printLog
prints a log message with the module name included.- Parameters:
log
-
-
getResourceDir
-
getFileList
-
getFileList
-
getFileList
-
writeFile
-
readFile
-
readFileString
-
getFileNamesRelative
-
createFileName
returns a new file name which is composed of the file name given and then by adding given string to it. if flag preservePath is true, then file name will have the same path as the original file name.- Parameters:
filename
-addition
-preservePath
-- Returns:
-
main
-