Here you can find the source of appendFile(String content, File file)
private static void appendFile(String content, File file) throws IOException
//package com.java2s; //License from project: Open Source License import java.io.*; public class Main { private static void appendFile(String content, File file) throws IOException { BufferedWriter writer = new BufferedWriter(new FileWriter(file, true)); writer.write(content);/*from w w w. ja v a 2 s . c om*/ writer.newLine(); writer.close(); } }