Class FileUtils


  • public class FileUtils
    extends Object
    The Class FileUtils.
    • Field Detail

      • STATUS_OK

        public static final boolean STATUS_OK
        The Constant STATUS_OK.
        See Also:
        Constant Field Values
      • STATUS_ERROR

        public static final boolean STATUS_ERROR
        The Constant STATUS_ERROR.
        See Also:
        Constant Field Values
    • Constructor Detail

      • FileUtils

        public FileUtils()
    • Method Detail

      • delete

        public static boolean delete​(File file,
                                     StringBuffer logBuffer)
        Delete.
        Parameters:
        file - the file
        logBuffer - the log buffer
        Returns:
        true, if successful
      • readFile

        public static String readFile​(String strFilePath)
        Read file.
        Parameters:
        strFilePath - the str file path
        Returns:
        the string
      • list

        public static List<String> list​(String strDirPath,
                                        String strFileExtension)
        List.
        Parameters:
        strDirPath - the str dir path
        strFileExtension - the str file extension
        Returns:
        the list
      • list

        public static List<String> list​(String strDirPath,
                                        String strFileExtension,
                                        boolean bRecursive)
        List.
        Parameters:
        strDirPath - the str dir path
        strFileExtension - the str file extension
        bRecursive - the b recursive
        Returns:
        the list