|
|
@@ -32,6 +32,14 @@ public final class IOStrings {
|
|
|
|
|
|
private IOStrings() { }
|
|
|
|
|
|
+ public static Reader reader(File file, Charset cs) throws IOException {
|
|
|
+ return new InputStreamReader(new FileInputStream(file), cs);
|
|
|
+ }
|
|
|
+
|
|
|
+ public static Writer writer(File file, Charset cs) throws IOException {
|
|
|
+ return new OutputStreamWriter(new FileOutputStream(file), cs);
|
|
|
+ }
|
|
|
+
|
|
|
public static void write(Writer writer, String content) throws IOException {
|
|
|
try {
|
|
|
writer.write(content);
|