240241242243244245246247
File.createTempFile("petersen-documents",".dat"); compressedDocumentsWriter = new DataOutputStream( new BufferedOutputStream( new FileOutputStream(compressedDocuments))); } catch (IOException ioe) { throw new IOError(ioe); } }
389390391392393394395396
try { // Wrap the call to avoid having all the code in a try/catch. This // is for improved readability purposes only. processSpace(); } catch (IOException ioe) { throw new IOError(ioe); } }
105106107108109110111112113
public synchronized Document next() { Document next = new StringDocument(nextLine); try { nextLine = advance(); } catch (IOException ioe) { throw new IOError(ioe); } return next; }
108109110111112113114115
} return questions; } catch (IOException ioe) { // rethrow, as any IOException is fatal to evaluation throw new IOError(ioe); } }
128129130131132133134135
curColumn = 0; isFinished = false; try { matrixWriter = new PrintWriter(matrixFile); } catch (IOException ioe) { throw new IOError(ioe); } }
142143144145146147148149150151
private static File getTempMatrixFile() { File tmp = null; try { tmp = File.createTempFile("matlab-sparse-matrix", ".dat"); } catch (IOException ioe) { throw new IOError(ioe); } tmp.deleteOnExit(); return tmp; }
6364656667686970
} writer.close(); return outputFile; } catch (IOException ioe) { throw new IOError(ioe); } }
101102103104105106107108109110
wordsAndNum[0], wordsAndNum[1], Double.parseDouble(wordsAndNum[2]))); } } catch (IOException ioe) { // rethrow as an IOE is fatal evaluation throw new IOError(ioe); } return pairs; }
5758596061626364
FileOutputStream fos = new FileOutputStream(output); ObjectOutputStream outStream = new ObjectOutputStream(fos); outStream.writeObject(wordToIndexVector); outStream.close(); } catch (IOException ioe) { throw new IOError(ioe); } }
74757677787980818283
Map<String, TernaryVector> vectorMap = (Map<String, TernaryVector>) inStream.readObject(); inStream.close(); return vectorMap; } catch (IOException ioe) { throw new IOError(ioe); } catch (ClassNotFoundException cnfe) { throw new Error(cnfe); } }