パッケージ nlp4j.util

クラス TextFileUtils


  • public class TextFileUtils
    extends Object
    • コンストラクタの詳細

      • TextFileUtils

        public TextFileUtils()
    • メソッドの詳細

      • write

        public static void write​(File outFile,
                                 List<String> data)
                          throws IOException
        Writes a data to a file creating the file if it does not exist.
        パラメータ:
        outFile - file the file to write
        data - the content to write
        例外:
        IOException - - in case of an I/O error
      • write

        public static void write​(File outFile,
                                 List<String> data,
                                 String encoding,
                                 boolean append)
                          throws IOException
        Writes a data to a file creating the file if it does not exist.
        パラメータ:
        outFile - file the file to write
        data - the content to write
        encoding - the name of the requested charset, null means platform default
        append - if true, then the data will be added to the end of the file rather than overwriting
        例外:
        IOException - - in case of an I/O error