Example usage for Java edu.stanford.nlp.io IOUtils fields, constructors, methods, implement or subclass
The text is from its open source code.
void | closeIgnoringExceptions(Closeable c) Provides an implementation of closing a file for use in a finally block so you can correctly close a file without even more exception handling stuff. |
PrintWriter | encodedOutputStreamPrintWriter(OutputStream stream, String encoding, boolean autoFlush) Create a Reader with an explicit encoding around an InputStream. |
BufferedReader | getBufferedFileReader(String filename) |
PrintWriter | getPrintWriter(File textFile) |
PrintWriter | getPrintWriter(String filename) |
BufferedReader | readerFromStdin(String encoding) Open a BufferedReader on stdin. |
BufferedReader | readerFromString(String textFileOrUrl, String encoding) Open a BufferedReader to a file or URL specified by a String name. |
BufferedReader | readerFromString(String textFileOrUrl) Open a BufferedReader to a file, class path entry or URL specified by a String name. |
ObjectInputStream | readStreamFromString(String filenameOrUrl) Returns an ObjectInputStream reading from any of a URL, a CLASSPATH resource, or a file. |
String | slurpFile(File file) Returns all the text in the given File as a single String. |
String | slurpFile(String filename) Returns all the text in the given file |
String | slurpFileNoExceptions(File file) Returns all the text in the given file with the given encoding. |
String | slurpFileNoExceptions(String filename) Returns all the text in the given file with the given encoding. |
String | slurpInputStream(InputStream input, String encoding) Read the contents of an input stream, decoding it according to the given character encoding. |