Java BufferedWriter Create getBufferedWriter(String path)

Here you can find the source of getBufferedWriter(String path)

Description

get Buffered Writer

License

Apache License

Declaration

public static BufferedWriter getBufferedWriter(String path) throws IOException 

Method Source Code

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

import java.io.BufferedWriter;

import java.io.FileOutputStream;

import java.io.IOException;
import java.io.OutputStreamWriter;

public class Main {
    public static BufferedWriter getBufferedWriter(String path) throws IOException {
        FileOutputStream fileOutputStream = new FileOutputStream(path);
        OutputStreamWriter out = new OutputStreamWriter(fileOutputStream, "utf-8");
        return new BufferedWriter(out);
    }//from  ww w. j a va2  s.  com
}

Related

  1. getBufferedWriter(OutputStream os)
  2. getBufferedWriter(String directory, String filename)
  3. getBufferedWriter(String file)
  4. getBufferedWriter(String file, String fileCharset)
  5. getBufferedWriter(String filePath, String encoding)
  6. getBufferedWriter(String path, String charset, boolean isAppend)
  7. getBufferedWriterOnFile(File file, String format)
  8. toBufferedWriter(Writer w)