@@ -0,0 +1,891 @@
+package file;%0A%0Aimport java.io.FileNotFoundException;%0Aimport java.io.FileOutputStream;%0Aimport java.io.IOException;%0A%0Apublic class Writer %7B%0A%09public static void write(byte%5B%5D content, String filePath)%7B%0A%09%09FileOutputStream fos = null;%0A%09%09try %7B%0A%09%09%09 fos = new FileOutputStream(filePath);%0A%09%09%7D catch (FileNotFoundException e) %7B%0A%09%09%09System.out.println(%22%5BERROR%5D: Can't find file named %5C%22%22 + filePath + %22%5C%22%22);%0A%09%09%09return;%0A%09%09%7D%0A%09%09%0A%09%09try %7B%0A%09%09%09fos.write(content);%0A%09%09%7D catch (IOException e1) %7B%0A%09%09%09System.out.println(%22%5BERROR%5D: Write data to file %5C%22%22 + filePath + %22%5C%22 failed%22);%0A%09%09%09try %7B%0A%09%09%09%09fos.close();%0A%09%09%09%7D catch (IOException e) %7B%0A%09%09%09%09System.out.println(%22%5BERROR%5D: Close file %5C%22%22 + filePath + %22%5C%22 failed%22);%0A%09%09%09%09return;%0A%09%09%09%7D%0A%09%09%09return;%0A%09%09%7D%0A%09%09%0A%09%09try %7B%0A%09%09%09if(fos != null)%7B%0A%09%09%09%09fos.close();%0A%09%09%09%7D%0A%09%09%7D catch (IOException e) %7B%0A%09%09%09System.out.println(%22%5BERROR%5D: Close file %5C%22%22 + filePath + %22%5C%22 failed%22);%0A%09%09%09return;%0A%09%09%7D%0A%09%7D%0A%7D%0A

Create Writer.java