Fastest way to write to file?

后端 未结 6 1898
难免孤独
难免孤独 2020-12-02 15:54

I made a method that takes a File and a String. It replaces the file with a new file with that string as its contents.

This is what I made

6条回答
  •  被撕碎了的回忆
    2020-12-02 16:04

    You could look into Java's NIO capabilities. It may support what you want to do.

    Java NIO FileChannel versus FileOutputstream performance / usefulness

提交回复
热议问题