public static void write(File file,CharSequence data,Charset encoding,boolean append) throws IOException {
  String str=data == null ? null : data.toString();
  writeStringToFile(file,str,encoding,append);
}

public static void write ( File file , CharSequence data , Charset encoding , boolean append ) throws IOException { String str = data == null ? null : data . toString ( ) ; writeStringToFile ( file , str , encoding , append ) ; }
writes a charsequence to a file creating the file if it does not exist .
