MCPcopy Create free account
hub / github.com/antlr/codebuff / toString

Method toString

corpus/java/training/guava/io/Files.java:261–263  ·  view source on GitHub ↗

Reads all characters from a file into a String, using the given character set. @param file the file to read from @param charset the charset used to decode the input stream; see StandardCharsets for helpful predefined constants @return a string containing all the characters from

(File file, Charset charset)

Source from the content-addressed store, hash-verified

259 * @throws IOException if an I/O error occurs
260 */
261 public static String toString(File file, Charset charset) throws IOException {
262 return asCharSource(file, charset).read();
263 }
264
265 /**
266 * Overwrites a file with the contents of a byte array.

Callers

nothing calls this directly

Calls 2

asCharSourceMethod · 0.95
readMethod · 0.45

Tested by

no test coverage detected