Here you can find the source of appendText(String path, String text)
public static boolean appendText(String path, String text)
//package com.java2s; //License from project: Open Source License import java.io.BufferedWriter; import java.io.File; import java.io.FileWriter; public class Main { public static boolean appendText(String path, String text) { try {//from ww w. java 2s . c o m File file = new File(path); System.out.println("file:" + file.getPath()); BufferedWriter writer = new BufferedWriter(new FileWriter(file, true)); writer.write(text); writer.close(); return true; } catch (Exception e) { e.printStackTrace(); } return false; } }