Java File Append appendFile(String fileName, String content)

Here you can find the source of appendFile(String fileName, String content)

Description

append File

License

Apache License

Declaration

public static void appendFile(String fileName, String content)
            throws IOException 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.io.*;

public class Main {
    public static void appendFile(String fileName, String content)
            throws IOException {
        PrintWriter out = new PrintWriter(new BufferedWriter(
                new FileWriter(fileName, true)));
        out.println(content);/*from w w  w.j ava  2  s . c o m*/
        out.close();
    }
}

Related

  1. appendFile(String file, byte[]... data)
  2. appendFile(String file, String content)
  3. appendFile(String file, String text)
  4. appendFile(String fileContents, File toFile)
  5. appendFile(String fileName, byte[] data)
  6. appendFile(String filename, String text)
  7. appendFile(String filename, String text)
  8. appendFile(String fileName, StringBuffer sb)
  9. appendFile(String fullName, String text)