Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
package chaschev.t1;
import com.google.common.io.CharStreams;
import com.google.common.io.Files;
import it.unimi.dsi.lang.MutableString;
import java.io.File;
import java.io.IOException;
import java.nio.charset.Charset;
public class CharStreamsExample {
public static void main(String[] args) throws IOException {
File file = new File("pom.xml");
MutableString str = new MutableString((int) file.length());
CharStreams.copy(Files.newReaderSupplier(file, Charset.defaultCharset()), str);
System.out.println(str);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.